Publishing your package to the ActiveState catalog allows the Platform to build the package and make it available to everyone in your organization. This is currently only available for Linux users.
Ensure the following conditions are met before you begin
.tar
file of the source code of your packageThe following will walk you through the process of
To publish to the ActiveState Platform
.tar
file, convert it to a tar filestate publish \
--namespace private/<orgname>/<language> \
--name <package-name> \
--version <version-number> \
--description "<package-description>" \
--author "name <<email>> \
--depend "<builder/python-module-builder@>=0>" \
--feature language/<language>/<package-name>@<version-number> \
<file-name>
email
, one set must remain in the final code)file-name
, namespace, package-name
, version-number
and builder dependency with the --depend
flag are all necessary for a successful publication.--depend
linesState publish \
--namespace private/MyOrg/python \
–-name MyPackage \
–- version 1.0.0 \
--description "This package provides utility functions" \
–-author "John Smith <jsmith@email.com> \
--depend "MyOrg/MyPackage@1.0.0" \
--feature language/python/MyPackage@1.0.0
MyPackage.tar.gz
After completing the file and saving it to your system, copy the contents of the file and paste it into your command line. This will publish your package to the ActiveState Platform.
Wait for a confirmation message in your terminal, you may be prompted to confirm your request. Press y
to confirm.
To publish to the ActiveState Platform using your project’s .yaml
file
.tar
file, convert it to a tar filename: <package-name>
namespace: private/<orgname>/<language>
version: "<version-number>"
description: <package-description>
authors:
- name: <author-name>
email: <author-email>
dependencies:
- dependency:
name: <dependency-name>
namespace: <dependency-namespace>
versionRequirements: '>=0'
features:
- name: <package-name>
namespace: private/<orgname>/<language>
version: "<version-number>"
--depend
lines - dependency:
name: <dependency-name>
namespace: <dependency-namespace>
versionRequirements: '>=0'
A complete example .yaml
file is shown below
name: libunistring-demo
namespace: private/ActiveStateBE/shared
version: "1.0.0"
description: Unicode string library
authors:
- name: John Smith
email: jsmith@email.org
dependencies:
- dependency:
name: autotools-builder
namespace: builder
versionRequirements: '>=0'
features:
- name: libunistring-demo
namespace: shared
version: "1.0.0"
After completing the file and saving it to your working directory, enter the following into your command line to publish the package to the ActiveState Platform
state publish --meta <yaml-file>.yaml <package-file>
For example
state publish --meta my-project.yaml TAR_FILE.tar.gz
Your package is now available on the ActiveState Platform. To install your package to your local system, either create a secure shell environment using
state shell <orgname>/<projectname>
Or begin using a previously checked-out project by entering
state use <orgname>/<projectname>
Install the newly published package to the runtime environment by entering
state install <package-name>
Your package is now installed to your project and available to use. Note that publishing a new package may cause other packages in your project to be rebuilt, leading to a longer build time.