Skip to content

Commit

Permalink
Merge pull request #82 from hookdeck/chore/ci-tag-version
Browse files Browse the repository at this point in the history
chore(CI): update how tag version is stored and accessed
  • Loading branch information
leggetter authored May 8, 2024
2 parents 10f0ad3 + 16fe237 commit f998bf9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -112,23 +112,24 @@ jobs:

- name: Get GitHub tag version
# Store the version, stripping any v-prefix
id: tag-version
run: |
TAG_VERSION=${GITHUB_REF_NAME#v}
echo Version: $TAG_VERSION
echo "TAG_VERSION=$TAG_VERSION" >> $GITHUB_ENV
echo "TAG_VERSION=$TAG_VERSION" >> $GITHUB_OUTPUT
- name: Update package.json version
uses: jossef/[email protected]
with:
file: package.json
field: version
value: ${TAG_VERSION}
value: ${{ steps.tag-version.outputs.TAG_VERSION }}

- name: Commit package.json version
uses: EndBug/add-and-commit@v9
with:
default_author: github_actions
message: 'Update package.json version to ${TAG_VERSION}'
message: 'Update package.json version to ${{ steps.tag-version.outputs.TAG_VERSION }}'
add: 'package.json'

- run: npm ci
Expand Down

0 comments on commit f998bf9

Please sign in to comment.