1+ # Copyright (c) JFrog Ltd. 2026
12name : Release
23
34on :
@@ -15,10 +16,12 @@ jobs:
1516 release :
1617 runs-on : ubuntu-latest
1718 steps :
18- - uses : actions/checkout@v4
19+ # Check out the repository with a token so the workflow can push tags
20+ - uses : actions/checkout@v5
1921 with :
2022 token : ${{ secrets.GITHUB_TOKEN }}
2123
24+ # Parse the commit message for a [major], [minor], or [patch] tag
2225 - name : Detect release tag in commit message
2326 id : detect
2427 run : |
@@ -29,21 +32,25 @@ jobs:
2932 echo "triggered=false" >> "$GITHUB_OUTPUT"
3033 fi
3134
35+ # Read the current version from the VERSION file
3236 - name : Read version
3337 if : steps.detect.outputs.triggered == 'true'
3438 id : version
3539 run : echo "version=$(cat VERSION)" >> "$GITHUB_OUTPUT"
3640
41+ # Create a git tag for the version and push it to origin
3742 - name : Create and push tag
3843 if : steps.detect.outputs.triggered == 'true'
3944 run : |
4045 git tag "v${{ steps.version.outputs.version }}"
4146 git push origin "v${{ steps.version.outputs.version }}"
4247
48+ # Bundle the plugin directory into a zip file for the GitHub Release
4349 - name : Package release artifact
4450 if : steps.detect.outputs.triggered == 'true'
4551 run : zip -r release.zip . --exclude ".git/*" --exclude ".github/*"
4652
53+ # Publish the GitHub Release with the zip artifact and auto-generated notes
4754 - name : Create GitHub Release
4855 if : steps.detect.outputs.triggered == 'true'
4956 env :
0 commit comments