-
-
Notifications
You must be signed in to change notification settings - Fork 11
PackageDefinition
A package defines a library and it's dependencies.
- version
- location
- dependencies
- Android manifest additions
- iOS Info Additions and Entitlements
- required configuration variables to be inserted into the above
A package is a single package file comprised of a series of files in a structure with a main "package definition" file.
A package is a zip file containing the following structure:
|____ package.json
|____ README.md
|____ CHANGELOG.md
|____ LICENSE.md
|____ android.xml
|____ ios.xml
|____ lib /
|____ [ANY SWC LIBRARIES CONTAINED IN THIS PACKAGE]
|____ src /
|____ [ANY AS3 SOURCE CONTAINED IN THIS PACKAGE]
|____ ane /
|____ [ANY EXTENSIONS CONTAINED IN THIS PACKAGE]
All of the content is optional, except the package definition json and a README.md file. All of the content packaged will be included in a build so don't include the source for a swc alongside the swc or you will end up with duplicate definitions. (You should create two different packages if you wish to create a source and compiled version of your package).
Normally a package should contain only one of the directories: lib
, src
, ane
.
A file(s) containing information about the library.
package.json
:
{
"id": "com.package.example",
"name": "Example package definition",
"url": "https://example.com/package/",
"description": "An example of a package definition",
"type": "swc",
"version":"1.0.0",
"checksum" : "XXXXXXXXX",
"dependencies": [
{
"id": "com.package.dependency.a",
"version": "2.4.0"
},
{
"id": "com.package.dependency.b",
"version": "3.1.0"
},
"com.package.dependency.c:4.0.0",
],
"configuration": [
"packageParam",
"requiredParam:required",
{
"name": "paramName",
"required": "true"
}
],
"sourceUrl": "https://example.com/package/swc/v1.0/com.package.example.zip"
}
Background
Client
Development