Skip to content

Commit

Permalink
ci: Better version fetching
Browse files Browse the repository at this point in the history
  • Loading branch information
judehunter committed Aug 12, 2023
1 parent ed57f48 commit 3c0ede5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/release_package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
if: startsWith(github.event.inputs.release-type, 'pre') != true
run: |
pnpm version $RELEASE_TYPE --no-git-tag-version --no-workspaces-update
echo "NEW_VERSION=$(cat package.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[",]//g')" >> $GITHUB_ENV
echo "NEW_VERSION=$(node -p -e "require('./package.json').version")" >> $GITHUB_ENV
echo "RELEASE_TAG=latest" >> $GITHUB_ENV
env:
RELEASE_TYPE: ${{ github.event.inputs.release-type }}
Expand All @@ -56,7 +56,7 @@ jobs:
if: startsWith(github.event.inputs.release-type, 'pre')
run: |
pnpm version $RELEASE_TYPE --no-git-tag-version --no-workspaces-update --preid=beta
echo "NEW_VERSION=$(cat package.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[",]//g')" >> $GITHUB_ENV
echo "NEW_VERSION=$(node -p -e "require('./package.json').version")" >> $GITHUB_ENV
echo "RELEASE_TAG=beta" >> $GITHUB_ENV
env:
RELEASE_TYPE: ${{ github.event.inputs.release-type }}
Expand Down

0 comments on commit 3c0ede5

Please sign in to comment.