File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 2121 python setup.py sdist
2222 twine check dist/*
2323
24+ # taken from https://python-semantic-release.readthedocs.io/en/latest/migrating_from_v7.html
2425 release :
2526 runs-on : self-hosted
2627 needs : test
@@ -29,26 +30,19 @@ jobs:
2930 refs/heads/main'
3031 , github.ref)
3132 concurrency : release
33+ permissions :
34+ id-token : write
3235 steps :
3336 - uses : actions/checkout@v3
3437 with :
3538 fetch-depth : 0
36- - name : Set up Python
37- uses : actions/setup-python@v4
39+ - name : Python Semantic Release
40+ id : release
41+ uses : python-semantic-release/python-semantic-release@v9.7.3
3842 with :
39- python-version : 3.11
40- - name : Install ci requirements
41- run : pip install -r ci-requirements.txt
42- - name : Release
43- run : |
44- git config --global user.email "infra@bimdata.io"
45- git config --global user.name "GA"
46- PYTHONPATH=$PWD python setup.py sdist
47- PYTHONPATH=$PWD semantic-release version
48- PYTHONPATH=$PWD twine upload --non-interactive dist/*
49- PYTHONPATH=$PWD semantic-release publish
50- env :
51- GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
52- PYPI_TOKEN : ${{ secrets.PYPI_TOKEN }}
53- TWINE_USERNAME : __token__
54- TWINE_PASSWORD : ${{ secrets.PYPI_TOKEN }}
43+ github_token : ${{ secrets.GITHUB_TOKEN }}
44+ - name : Publish package distributions to PyPI
45+ uses : pypa/gh-action-pypi-publish@release/v1
46+ # NOTE: DO NOT wrap the conditional in ${{ }} as it will always evaluate to true.
47+ # See https://github.com/actions/runner/issues/1173
48+ if : steps.release.outputs.released == 'true'
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments