This lesson explains several ways to add assets to packages, as well as how to manage the assets and dependencies already in the package for maximum usefulness.
As long as your version is a draft, you can modify assets and dependencies. The assets that you work with while drafting a new version are live, meaning that the assets that you see are how they are currently saved on the source site (not how they are published). Any changes you make on the source site will be visible in the draft version, although some changes might not be visible until the draft is either edited, activated, or pre-activated.
Update, and Trashed assets indicate primary “ownership” of the asset and can only be included in a single package. To include that asset in a second package the first package must be added as a dependency instead. Note that this ownership is determined by the latest version of each package and does NOT take into account old or draft versions.
Ignored, InstallOnly, MapRequired, and MapOptional assets indicate a looser “relationship” between a package version and an asset and may be included in as many packages as desired.
Dependencies must be installed at the same time or before the package version that defines it as a dependency.
The only assets you should typically need to manage most of the time are InstallOnly and Update assets. When a new draft is created, and when a draft is pre-activated, Marketpath will automatically curate your Trashed, MapOptional, and MapRequired assets - although adding and updating the descriptions will be up to you.
You do not have to manually track all of the Map (Optional) and Map (Required) assets since these will automatically be added, updated, and removed for you as necessary prior to activating the new version. You may want to review the mapped assets prior to activating a new version in order to consider 2 things:
Oftentimes, one part of a website is dependent on another. In this way you can build complex and flexible sites very quickly from a variety of reusable components. In Marketpath CMS Package Manager we define these components using dependent packages.
When installing a package with dependencies, the dependent packages must either already be installed on the site or may be installed at the same time.
However, it is common for packages to change over time so that new features or components are added and old ones removed. When you define a dependent package, you can select the minimum version for that package. The most common values are either to allow any version (no minimum version) or to require the latest version of a dependent package at the time that your package is released.
Because of the dramatically increased complexity, Marketpath CMS does not allow you to define a maximum version for a package - which means that future updates to dependent packages could potentially break your package. There are generally three ways to handle this challenge:
Please fill out the form below with your feedback or any questions you may have after working through the "Managing Assets and Dependencies" lesson.