UPack Documentation

Specifications

  • Last Modified: 2019-02-14

Virtual Content Object

This object describes a remote file or folder within either the contents root (package/) or package root (/) folder, depending on whether it's within the contents or metaContents property.

Property Format
type A string of either virtualDirectory or virtualFile that describes the content to be added. The default value is virtualDirectory, and is used only in the case of a missing property. All other values (including null or empty) are invalid.
virtualPath A string of a path to a file or folder within either the contents root (package/) or package root (/) folder, depending on whether the object is within the contents or metaContents property.

A missing property, or null, empty, or "/" string means the root within that path.

When used in metaContent, a value of upack.json is invalid, as the manifest can never be virtualized. A value that begins with package/ is also invalid for metaContent.
source One of the following values:

Package Source Object

This object describes where either a virtualFile or virtualFolder (as specified by the parent object) can be found.

Property Format
group A string of the referenced package group. When not specified, the empty group is used.
nameR A string of the referenced package name.
versionR A string of the referenced package version.
hash A package hash string used to verify the package file
packagePath A string containing the path within the package file (i.e. under the / directory of the archive file) the content can be found. A missing property, or null value will default to package/.

File Source Object

This object describes where a virtualFile can be found.

Property Format
urlR A string of an absolute HTTP/HTTPS resource where file contents can be foud
hash A hash string with the same format as a package hash string used to verify the file

Is this documentation incorrect or incomplete? Help us by contributing!

This documentation is licensed under CC-BY-SA-4.0 and stored in GitHub.