Skip to content

Commit

Permalink
Fix release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Corb3nik committed Oct 14, 2024
1 parent f8d1919 commit bd322bf
Showing 1 changed file with 16 additions and 16 deletions.
32 changes: 16 additions & 16 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,19 +29,19 @@ jobs:
version: ${{ env.PNPM_VERSION }}
run_install: true

- name: Publish
shell: bash
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
# Read the current version from package.json
CURRENT_VERSION=$(jq -r '.version' ./package.json)
# Check if the version contains "-beta"
if [[ "$CURRENT_VERSION" == *"-beta"* ]]; then
echo "Publishing $CURRENT_VERSION as beta tag"
pnpm publish --access public --tag beta
else
echo "Publishing $CURRENT_VERSION as latest tag"
pnpm publish --access public
fi
- name: Publish
shell: bash
env:
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
run: |
# Read the current version from package.json
CURRENT_VERSION=$(jq -r '.version' ./package.json)
# Check if the version contains "-beta"
if [[ "$CURRENT_VERSION" == *"-beta"* ]]; then
echo "Publishing $CURRENT_VERSION as beta tag"
pnpm publish --access public --tag beta
else
echo "Publishing $CURRENT_VERSION as latest tag"
pnpm publish --access public
fi

0 comments on commit bd322bf

Please sign in to comment.