Skip to content

Commit

Permalink
(DiamondLightSource/hyperion#819) Additional steps to create a releas…
Browse files Browse the repository at this point in the history
…e and edit release notes
  • Loading branch information
rtuck99 committed Apr 10, 2024
1 parent 42c5729 commit 5150999
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion .github/workflows/pre_release_workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ on:
jobs:
pin_dependency_versions:
runs-on: ubuntu-latest
env:
GH_TOKEN: ${{secrets.GITHUB_TOKEN}}
steps:
- name: Setup Python
uses: actions/setup-python@v5
Expand All @@ -28,11 +30,19 @@ jobs:
MSG=$(.github/workflows/pin_versions.py)
echo "COMMIT_MESSAGE=\"$MSG\"" >> "$GITHUB_OUTPUT"
- name: Add setup.cfg
run: git add setup.cfg
run: |
git add setup.cfg
- name: Commit changes
run: |
git config --global user.name "GitHub Workflow"
git config --global user.email "[email protected]"
git commit -m ${{steps.pin_versions.outputs.COMMIT_MESSAGE}}
git tag ${{inputs.tagName}}
git push origin ${{inputs.tagName}}
- name: Create Release
run: gh release create --generate-notes --draft ${{inputs.tagName}}
- name: Edit Release Notes
run: |
echo -e "${{ steps.pin_versions.outputs.COMMIT_MESSAGE }}\n\n" > "$RUNNER_TEMP/relnotes.txt"
gh release view ${{ inputs.tagName }} | sed '0,/^--$/d' >> "$RUNNER_TEMP/relnotes.txt"
gh release edit ${{ inputs.tagName }} --notes-file "$RUNNER_TEMP/relnotes.txt"

0 comments on commit 5150999

Please sign in to comment.