Skip to content

v0.1.3

v0.1.3 #2

Workflow file for this run

---
name: "release"
on: # yamllint disable
release:
types:
- "published"
jobs:
build:
name: "Build package with poetry"
# https://github.com/actions/runner-images/blob/main/images/ubuntu/Ubuntu2404-Readme.md
runs-on: "ubuntu-24.04"
steps:
- uses: "actions/checkout@v4"
- run: "pipx install poetry"
- run: "poetry build"
- uses: "actions/upload-artifact@v4"
with:
name: "distfiles"
path: "dist/"
if-no-files-found: "error"
publish-github:
name: "Upload to GitHub Release"
runs-on: "ubuntu-24.04"
permissions:
contents: "write"
needs: "build"
steps:
- uses: "actions/checkout@v4"
- uses: "actions/download-artifact@v4"
with:
name: "distfiles"
path: "dist/"
- run: "gh release upload ${{ github.event.release.tag_name }} dist/*.{tar.gz,whl}"
env:
GH_TOKEN: "${{ github.token }}"
publish-pypi:
name: "Upload to PyPI"
runs-on: "ubuntu-24.04"
environment:
name: "pypi"
url: "https://pypi.org/p/mkdocs-ansible-collection"
permissions:
id-token: "write"
needs: "build"
steps:
- uses: "actions/download-artifact@v4"
with:
name: "distfiles"
path: "dist/"
- name: "Publish package distributions to PyPI"
uses: "pypa/gh-action-pypi-publish@release/v1"