@@ -44,32 +44,22 @@ jobs:
44
44
git config user.email "[email protected] "
45
45
46
46
- name : Bump the tag version
47
- id : create_branch
48
- # --no-git-tag-version ensures we control when tags are pushed
49
- # git fetch origin main
50
- # git checkout -b release/bump-tag-version origin/main
47
+ id : bump_npm_version
51
48
run : |
52
49
npm version ${{ github.event.inputs.release_type }} -m "chore(release): bump tag version to %s"
53
- # --follow-tags is not used when pushing the branch in the next step since we're using --no-git-tag-version here
54
-
55
- # - name: Commit version bump
56
- # run: |
57
- # git add package.json
58
- # git commit -m "chore(release): bump tag version to $(jq -r .version package.json)" || echo "No changes to commit"
59
- # git push origin release/bump-tag-version
60
-
61
- # Duplicate
62
- # - name: Configure Git credentials
63
- # run: |
64
- # git config --global url."https://github.com/".insteadOf "[email protected] :"
65
- # git config --global credential.helper store
66
50
67
51
# - name: Debug Git state
68
52
# run: |
69
53
# git remote -v
70
54
# git branch
71
55
# git config --list
72
56
57
+ - name : Extract the new version from package.json
58
+ id : capture_version
59
+ run : |
60
+ VERSION=$(jq -r .version package.json)
61
+ echo "new_version=${VERSION}" >> $GITHUB_OUTPUT
62
+
73
63
- name : Generate changelog
74
64
continue-on-error : true
75
65
run : ./update_changelog.sh
@@ -80,11 +70,11 @@ jobs:
80
70
GITHUB_TOKEN :
81
71
with :
82
72
token : ${{ secrets.GITHUB_TOKEN }}
83
- branch : " release/bump-tag-version"
84
- # branch-suffix: "short-commit-hash"
73
+ branch : " release/bump-tag-version-and-update-changelog "
74
+ branch-suffix : " short-commit-hash"
85
75
base : " main"
86
76
title : " chore(release): Bump tag version and update changelog"
87
77
commit-message : " chore(release): Bump tag version and update changelog"
88
78
body : |
89
- This pull request bumps the tag version to $(jq -r .version package.json) and updates changelog as part of the release process.
79
+ This pull request bumps the tag version to ${{ steps.capture_version.outputs.new_version }} and updates changelog as part of the release process.
90
80
Please review and merge.
0 commit comments