HELICS Version Update #42
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: HELICS Version Update | |
on: | |
workflow_dispatch: | |
inputs: | |
version: | |
description: 'HELICS version number (without leading `v` prefix)' | |
required: true | |
type: string | |
dryrun: | |
description: 'Do a dry run of the update process, without making the commit' | |
required: false | |
type: boolean | |
jobs: | |
update-version: | |
runs-on: ubuntu-latest | |
if: github.event.action == 'helics-version-update' | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Update the HELICS_VERSION file to ${{ inputs.version }} | |
run: echo "${{ inputs.version }}" > HELICS_VERSION | |
- name: Commit updated HELICS_VERSION file | |
run: | | |
git config --global user.name "github-actions[bot]" | |
git config --global user.email "github-actions[bot]@users.noreply.github.com" | |
git add HELICS_VERSION && git commit -m "Update HELICS version to ${{ inputs.version }}" | |
- name: Push updated HELICS_VERSION file | |
run: | | |
if [ "${{ inputs.dryrun }}" = "false" ]; then | |
echo "Pushing changes" | |
git push | |
fi |