Skip to content

Commit 7b28273

Browse files
Update release.yml (#69)
* Update release.yml * Update package.json --------- Co-authored-by: Denis Tokarev <[email protected]>
1 parent 65317e5 commit 7b28273

File tree

2 files changed

+8
-1
lines changed

2 files changed

+8
-1
lines changed

.github/workflows/release.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,8 @@ jobs:
9292
changelog:
9393
name: Generate new changelog
9494
runs-on: ubuntu-latest
95+
outputs:
96+
commit_hash: '${{ steps.committing.outputs.commit_hash }}'
9597
steps:
9698
- name: Checkout
9799
uses: actions/checkout@v4
@@ -154,6 +156,7 @@ jobs:
154156
name: changelog
155157
path: CHANGELOG.md
156158
- name: Commit and push the new changelog
159+
id: committing
157160
run: |
158161
if [ -z $(git status -uno --porcelain) ]; then
159162
printf 'Changelogs are identical, nothing to commit\n'
@@ -164,6 +167,9 @@ jobs:
164167
165168
git add CHANGELOG.md
166169
git commit -am "Update the project changelog"
170+
171+
commit_hash=$( git --no-pager log -1 --format=%H )
172+
echo "commit_hash=${commit_hash}" >> "$GITHUB_OUTPUT"
167173
fi
168174
- name: Push changes
169175
uses: ad-m/[email protected]
@@ -181,6 +187,7 @@ jobs:
181187
uses: actions/checkout@v4
182188
with:
183189
set-safe-directory: 'true'
190+
ref: '${{ needs.changelog.outputs.commit_hash }}'
184191
- name: Install dependencies
185192
run: npm ci --ignore-scripts
186193
- name: Maybe generate tag

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "async-wait-until",
3-
"version": "2.0.24",
3+
"version": "2.0.25",
44
"description": "Waits until the given predicate function returns a truthy value, then resolves",
55
"main": "./dist/index.js",
66
"module": "./dist/index.esm.js",

0 commit comments

Comments
 (0)