4.14.0 #10
Workflow file for this run
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: Update Version Number | |
on: | |
release: | |
types: [published] | |
jobs: | |
update-version-number: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Repository | |
uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4 | |
with: | |
fetch-depth: 0 | |
- name: Update Version Number | |
run: | | |
OLD_VERSION=`cat pyproject.toml | grep ^version | cut -d '"' -f 2` | |
OLD_VERSION="\"$OLD_VERSION\"" | |
NEW_VERSION="\"$GITHUB_REF_NAME\"" | |
sed -i "s+version = $OLD_VERSION+version = $NEW_VERSION+g" pyproject.toml | |
- name: Commit Changes | |
run: | | |
git config user.name "$GITHUB_ACTOR" | |
git config user.email "[email protected]" | |
git commit -a -m "Update version number to new_version" | |
git push origin HEAD:main |