1
Add package metadata
Packages need some additional metadata in their
ato.yaml
config to explain what they are, their version and to give you credit.2
Setup GitHub Action
Install and configure our
atopile/publish-package
action.3
Publish
The action will automatically package and publish your project whenever you’re ready!
- A single package in the repo, like nonos.
- A monorepo with multiple separate packages, like packages. This is common when you’re a larger org, and have a lot to share.
Making good packages
Documentation goes a long way to smooth setup! A useful summary helps, but aREADME.md
is even better.
The package index automatically detects your README.md
, and will display the it for you.
Currently, the package index doesn’t support image uploads. If you want this, check out https://github.com/atopile/atopile/issues/1156
Package Metadata
Here’s an example of some package metadata. Copying this, and updating it with your own information is a good place to start. The first section of the identifier must be your GitHub username or organization name. This is enforced on upload.- Single Package
- Monorepo
Recommendations:
- Name the repo the same as the package.
- Version the package with releases, and use the tag as the version.
ato.yaml
Configuring your publish workflow
Publishing is currently supported exclusively through the atopile/publish-package action.The reason only GitHub is supported at the moment is because we only currently support GitHub OIDC tokens for authorization.
- Single Package
- Monorepo
Recommendations:
- Name the repo the same as the package.
- Version the package with releases, and use the tag as the version.
Hitting “publish”!
This must be a valid semver string, with the following additional restrictions:- No leading
v
character - No pre-release or dev tags
- No build metadata
1.2.3
- Single Package
- Monorepo
Create a release on GitHub, tagged as the version you want to publish.
Reference
Nitty gritty details for advanced configuration.Package Metadata
package.identifier
The identifier is a unique identifier for the package. It must be in the form {owner}/{name}
, where owner
is your GitHub username or organization name.
If the URL to your repository is https://github.com/atopile/packages
, then your “owner” is atopile
.
You can name your package whatever you want, but it must be unique within the owner.
package.repository
The repository is the URL to the repository containing the package source code. This should be a link to the repository on GitHub.
package.version
[optional]
The version is the version of the package.
This must be a valid semver string, with the following additional restrictions:
- No leading
v
character - No pre-release or dev tags
- No build metadata
package-version
action input instead.
package.authors
The authors are the people who should be credited for the package.
This is a list, with each entry having a name
and email
.