2025-04-27 10:59:15 +03:00
|
|
|
# pio pkg
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
> Manage packages in the registry.
|
|
|
|
> Packages can only be removed within 72 hours (3 days) from the date that they are published.
|
|
|
|
> More information: <https://docs.platformio.org/en/latest/core/userguide/package/>.
|
|
|
|
|
|
|
|
- Create a package tarball from the current directory:
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg pack {{[-o|--output]}} {{path/to/package.tar.gz}}`
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
- Create and publish a package tarball from the current directory:
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg publish`
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
- Publish the current directory and restrict public access to it:
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg publish --private`
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
- Publish a package:
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg publish {{path/to/package.tar.gz}}`
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
- Publish a package with a custom release date (UTC):
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg publish {{path/to/package.tar.gz}} --released-at "{{2021-04-08 21:15:38}}"`
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
- Remove all versions of a published package from the registry:
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg unpublish {{package}}`
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
- Remove a specific version of a published package from the registry:
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg unpublish {{package}}@{{version}}`
|
2021-04-10 21:23:12 +02:00
|
|
|
|
|
|
|
- Undo the removal, putting all versions or a specific version of the package back into the registry:
|
|
|
|
|
2025-04-27 10:59:15 +03:00
|
|
|
`pio pkg unpublish --undo {{package}}@{{version}}`
|