typo fix for pypi workflow #2
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: publish-roodmus-to-pypi | ||
on: push | ||
jobs: | ||
build: | ||
name: build-dist | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: setup-python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: "3.10.4" | ||
- name: install-pypa/build | ||
run: >- | ||
python3 -m | ||
pip install | ||
build | ||
--user | ||
- name: build-bin-whl | ||
run: python3 -m build | ||
- name: grab-build | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: pkg-dist | ||
path: dist/ | ||
publish-to-pypi: | ||
name: >- | ||
publish-to-pypi | ||
if: startsWith(github.ref, 'ref/tags/') | ||
needs: | ||
- build | ||
runs-on: ubuntu-latest | ||
environment: | ||
name: production | ||
url: https://pypi.org/p/roodmus | ||
permissions: | ||
id-token: write | ||
steps: | ||
- name: download-dists | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: pkg-dist | ||
path: dist/ | ||
- name: publish-dist-to-pypi | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
github-release: | ||
name: >- | ||
sign-dist-via-sigstore-and-upload-to-github-release | ||
needs: | ||
- publish-to-pypi | ||
runs-on: ubuntu-latest | ||
permissions: | ||
contents: write | ||
id-token: write | ||
steps: | ||
- name: download-dists | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: pkg-dist | ||
path: dist/ | ||
- name: sign-dists | ||
uses: sigstore/[email protected] | ||
with: | ||
inputs: >- | ||
./dist/*.tar.gz | ||
./dist/*.whl | ||
- name: create-github-release | ||
env: | ||
GITHUB_TOKEN: ${{ github.token }} | ||
run: >- | ||
gh release create | ||
'${{ github.ref_name }}' | ||
--repo '${{ github.repository }}' | ||
--notes "" | ||
- name: upload-artifact-signature-to-github-release | ||
env: | ||
GITHUB_TOKEN: ${{ github.token }} | ||
run: >- | ||
gh release upload | ||
'${{ github.ref_name }}' dist/** | ||
--repo '${{ github.repository }}' | ||
publish-to-test-pypi: | ||
name: publish-to-test-pypi | ||
if: startsWith('ref/head/main', 'ref/head/development', 'ref/tags/') | ||
Check failure on line 93 in .github/workflows/publish-to-pypi.yml GitHub Actions / publish-roodmus-to-pypiInvalid workflow file
|
||
needs: | ||
- build | ||
runs-on: ubuntu-latest | ||
environment: | ||
name: testing | ||
url: https://test.pypi/org/p/roodmus | ||
permissions: | ||
id-token: write | ||
steps: | ||
- name: download-dists | ||
uses: actions/download-artifact@v3 | ||
with: | ||
name: pkg-dist | ||
path: dist/ | ||
- name: publish-dist-to-test-pypi | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
repository-url: https://test.pypi.org/ |