Skip to content

Commit

Permalink
TENT-5976 fix: Release to NPM before bumping up project version to n…
Browse files Browse the repository at this point in the history
…ext dev version (#64)
  • Loading branch information
sebastianbarth-disy authored Nov 7, 2024
1 parent d81e0bd commit 794c27f
Showing 1 changed file with 16 additions and 11 deletions.
27 changes: 16 additions & 11 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,17 +57,6 @@ jobs:
git commit -m "chore: release ${{ env.RELEASE_VERSION }}"
git tag ${{ env.RELEASE_VERSION }}
- name: Bump package version to new dev version (e.g. 1.2.3 => 1.2.4-dev)
run: |
npm --no-git-tag-version version patch # Determine next release version
DEV_VERSION=$(npm pkg get version | tr -d \")-dev && echo "DEV_VERSION=$DEV_VERSION" >> $GITHUB_ENV # Determine DEV_VERSION with -dev suffix
npm --no-git-tag-version version $DEV_VERSION # Set main to $DEV_VERSION
- name: Commit version bump
run: |
git add "package.json"
git commit -m "chore: bump up version to ${{ env.DEV_VERSION }}"
- name: Push changes
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down Expand Up @@ -95,3 +84,19 @@ jobs:
npm publish --verbose --access=public --tag=${{ env.RELEASE_TAG }}
env:
NPM_TOKEN: ${{ secrets.NPMJS_ACCESS_TOKEN }}

- name: Bump package version to new dev version (e.g. 1.2.3 => 1.2.4-dev)
run: |
npm --no-git-tag-version version patch # Determine next release version
DEV_VERSION=$(npm pkg get version | tr -d \")-dev && echo "DEV_VERSION=$DEV_VERSION" >> $GITHUB_ENV # Determine DEV_VERSION with -dev suffix
npm --no-git-tag-version version $DEV_VERSION # Set main to $DEV_VERSION
- name: Commit version bump
run: |
git add "package.json"
git commit -m "chore: bump up version to ${{ env.DEV_VERSION }}"
- name: Push changes
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: git push origin

0 comments on commit 794c27f

Please sign in to comment.