-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #15 from timmyb824/ci/switch-semantic-release-back…
…-to-shell
- Loading branch information
Showing
1 changed file
with
21 additions
and
17 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -92,32 +92,36 @@ jobs: | |
run: | | ||
python -m poetry install --no-root | ||
# - name: Prepare package for release | ||
# env: | ||
# GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
# run: | | ||
# git config user.name github-actions | ||
# git config user.email [email protected] | ||
# poetry run semantic-release version | ||
# poetry run semantic-release changelog | ||
# poetry run semantic-release publish | ||
|
||
- name: Run Python Semantic Release | ||
- name: Prepare package for release | ||
id: release | ||
uses: python-semantic-release/python-semantic-release@master | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
shell: bash | ||
env: | ||
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
git config user.name github-actions | ||
git config user.email [email protected] | ||
poetry run semantic-release version | ||
poetry run semantic-release changelog | ||
poetry run semantic-release publish | ||
# Unable to use at the moment due to the python version used by the action | ||
# - name: Run Python Semantic Release | ||
# id: release | ||
# uses: python-semantic-release/python-semantic-release@master | ||
# with: | ||
# github_token: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Publish to TestPyPI | ||
if: steps.release.outputs.released == 'true' | ||
id: test_publish | ||
if: steps.release.outcome == 'success' | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.TEST_PYPI_API_TOKEN }} | ||
repository-url: https://test.pypi.org/legacy/ | ||
|
||
- name: Test install from TestPyPI | ||
if: steps.release.outputs.released == 'true' | ||
if: steps.test_publish.outcome == 'success' | ||
shell: bash | ||
id: test_install | ||
run: | | ||
|
@@ -128,7 +132,7 @@ jobs: | |
- name: Publish to PyPI | ||
uses: pypa/gh-action-pypi-publish@release/v1 | ||
if: steps.release.outputs.released == 'true' && steps.test_install.outcome == 'success' | ||
if: steps.test_install.outcome == 'success' | ||
with: | ||
user: __token__ | ||
password: ${{ secrets.PYPI_API_TOKEN }} | ||
|