Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/alirezatheh/pypi-auto-publish
GitHub action to automate build and publish PEP 518 compliant projects (Setuptools, Flit, Poetry) on Test PyPI and/or PyPI if local package.__version__ is ahead of PyPI’s.
https://github.com/alirezatheh/pypi-auto-publish
actions github github-actions publish pypi pypi-package release release-automation
Last synced: about 1 month ago
JSON representation
GitHub action to automate build and publish PEP 518 compliant projects (Setuptools, Flit, Poetry) on Test PyPI and/or PyPI if local package.__version__ is ahead of PyPI’s.
- Host: GitHub
- URL: https://github.com/alirezatheh/pypi-auto-publish
- Owner: AlirezaTheH
- License: mit
- Created: 2022-05-24T19:59:11.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-03-08T16:57:14.000Z (8 months ago)
- Last Synced: 2024-10-11T09:34:18.750Z (about 1 month ago)
- Topics: actions, github, github-actions, publish, pypi, pypi-package, release, release-automation
- Language: Python
- Homepage:
- Size: 18.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
# PyPI Auto Publish
GitHub action to automate build and publish
[PEP 518](https://peps.python.org/pep-0518/) compliant projects (Setuptools,
Flit, Poetry) on Test PyPI and/or PyPI if local `package.__version__` is ahead
of PyPI's.## Usage
```yaml
name: Publish
on:
push:
branches:
- main
workflow_dispatch:jobs:
pypi-publish:
runs-on: ubuntu-latest
steps:
- uses: alirezatheh/pypi-auto-publish@v1
with:
test-api-pypi-token: ${{ secrets.TEST_PYPI_API_TOKEN }}
pypi-api-token: ${{ secrets.PYPI_API_TOKEN }}
```The action assume:
- The project has a `setup.py`, `setup.cfg` or `pyproject.toml` in the
top-level directory.
- Python and pip are installed (e.g. by `actions/setup-python@v3`).## Inputs
- `test-api-pypi-token`: API token of the Test PyPI account publishing the
project. If missing, publish on Test PyPI is skipped (optional).
- `pypi-api-token`: API token of the PyPI account publishing the project
(required).
- `package-name`: Name of the PyPI package, Defaults to repository name
(optional).## Acknowledgements
This action is inspired by
[pypi-auto-publish](https://github.com/etils-actions/pypi-auto-publish)