v0.0.1-alpha.2 #3
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
name: release | |
on: | |
release: | |
types: [published] | |
jobs: | |
publish-to-testpypi: | |
name: Publish ansible-creator 🛠️ package 📦 to PyPI | |
if: github.event_name == 'release' | |
environment: release | |
runs-on: ubuntu-22.04 | |
permissions: | |
id-token: write # IMPORTANT: mandatory for trusted publishing | |
steps: | |
- name: Switch to using Python 3.9 by default | |
uses: actions/setup-python@v4 | |
with: | |
python-version: 3.9 | |
- name: Install build | |
run: >- | |
python3 -m | |
pip install | |
--user | |
build | |
- name: Check out src from Git | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 # needed by setuptools-scm | |
- name: Build dists | |
run: python -m build | |
- name: Publish to pypi.org | |
uses: pypa/gh-action-pypi-publish@release/v1 |