-
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.
uses python-semantic-release, on merged pull-request into any branch (although pyproject.toml specifies only main is used for versioning). Can also be triggered manually.
- Loading branch information
1 parent
3aa689b
commit 56c207b
Showing
1 changed file
with
35 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: Bump version (if necessary) | ||
|
||
on: | ||
pull_request_target: | ||
types: | ||
- closed | ||
workflow_dispatch: | ||
|
||
jobs: | ||
bump-version: | ||
if: (github.event.pull_request.merged == true) || (github.event_name == 'workflow_dispatch') | ||
runs-on: ubuntu-latest | ||
concurrency: bump-version | ||
permissions: | ||
id-token: write | ||
contents: write | ||
|
||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v3 | ||
with: | ||
fetch-depth: 0 # checkout full commit history | ||
token: ${{ secrets.GHA_Token }} | ||
|
||
- name: Python Semantic Release | ||
id: versioning | ||
uses: python-semantic-release/python-semantic-release@master | ||
with: | ||
github_token: ${{ secrets.GHA_TOKEN }} | ||
|
||
- name: Publish package distributions to GitHub Releases | ||
uses: python-semantic-release/upload-to-gh-release@main | ||
if: steps.versioning.outputs.released == 'true' | ||
with: | ||
github_token: ${{ secrets.GHA_TOKEN }} |