Update release workflow with commit message variable
All checks were successful
Release Creation / build (release) Successful in 35s
All checks were successful
Release Creation / build (release) Successful in 35s
- Added a new step to the release workflow that sets a commit message variable. - This step ensures that the commit message is captured and stored for future reference. - The commit message is retrieved using the `steps.commit-message.outputs.COMMIT_MESSAGE` variable. Update release workflow to use commit message variable - Updated the release workflow to use the commit message variable. - This change ensures that the commit message is used when creating a release. - The commit message is now stored in the `$GITHUB_OUTPUT` file and can be accessed by other steps in the workflow.
This commit is contained in:
@@ -35,12 +35,19 @@ jobs:
|
||||
&& cp src/module.json dist/
|
||||
&& echo \"Done!\nArchived to ${ZIP_FILENAME} and copied module.js.\"
|
||||
|
||||
- name: Setting commit message
|
||||
- name: Setting commit message variable
|
||||
id: commit-message
|
||||
run: >
|
||||
COMMIT_MESSAGE=$(git log -1 --pretty=%B);
|
||||
echo "COMMIT_MESSAGE=$COMMIT_MESSAGE" >> "$GITHUB_OUTPUT"
|
||||
&& echo "commit message is '$COMMIT_MESSAGE'"
|
||||
# Per
|
||||
# https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/workflow-commands-for-github-actions#example-of-a-multiline-string
|
||||
run: |
|
||||
{
|
||||
echo 'COMMIT_MESSAGE<<EOF'
|
||||
git log -1 --pretty=%B
|
||||
echo EOF
|
||||
} >> "$GITHUB_OUTPUT"
|
||||
|
||||
- name: retreive commit message
|
||||
run: echo "commit message is ${{ steps.commit-message.outputs.COMMIT_MESSAGE }}"
|
||||
|
||||
# Create a release for this specific version
|
||||
- name: Update Release with Files
|
||||
|
||||
Reference in New Issue
Block a user