Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(cicd): Automate release creation on tag push
These CI/CD improvements also bring test coverage tracking, and better naming for test steps.
- Loading branch information
1 parent
bdaa841
commit b2e195b
Showing
4 changed files
with
70 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 |
---|---|---|
@@ -1,20 +1,22 @@ | ||
name: PyPI deploy | ||
on: | ||
push: | ||
tags: '*' | ||
release: | ||
types: [created] | ||
|
||
jobs: | ||
deploy: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-python@v2 | ||
- name: Set up Python 3.9 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: 3.9 | ||
- uses: abatilo/actions-poetry@v2.1.3 | ||
- name: install | ||
- name: Install Poetry | ||
uses: abatilo/actions-poetry@v2.1.3 | ||
- name: Install redtape with Poetry | ||
run: poetry install | ||
- name: build | ||
- name: Build redtape with Poetry | ||
run: poetry build | ||
- name: publish | ||
- name: Publish redtape to Pypi with Poetry | ||
run: poetry publish --username __token__ --password ${{ secrets.PYPI_API_TOKEN }} |
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 |
---|---|---|
@@ -0,0 +1,38 @@ | ||
name: Tagged release | ||
|
||
on: | ||
push: | ||
tags: | ||
- "v*" | ||
|
||
jobs: | ||
gh_tagged_release: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Wait for Tests to succeed | ||
uses: fountainhead/action-wait-for-check@v1.0.0 | ||
id: wait-for-test | ||
with: | ||
token: ${{ secrets.PA_TOKEN }} | ||
checkName: test | ||
ref: ${{ github.sha }} | ||
- uses: actions/checkout@v2.3.4 | ||
- name: Set up Python 3.9 | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: '3.9' | ||
- name: Install Poetry | ||
uses: abatilo/actions-poetry@v2.1.4 | ||
with: | ||
poetry-version: 1.1.12 | ||
- name: Install redtape with Poetry | ||
run: poetry install | ||
- name: Build redtape with Poetry | ||
run: poetry build | ||
- name: Release new SemVer tag | ||
uses: marvinpinto/action-automatic-releases@latest | ||
with: | ||
repo_token: "${{ secrets.PA_TOKEN }}" | ||
prerelease: false | ||
files: | | ||
dist/* |
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
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