Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions .github/workflows/npm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,13 @@ jobs:
run: |
echo "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}" > ~/.npmrc

npm version patch -m "ci: release %s"
npm publish || echo "Version already published, skipping..."
NEW_VERSION=$(npm version patch -m "ci: release %s")
CURRENT_VERSION=$(npm view @fydemy/ui version)

if [ "$CURRENT_VERSION" = "$NEW_VERSION" ]; then
echo "Version $NEW_VERSION already exists, skipping publish"
else
npm publish
fi

git push https://${GH_TOKEN}@github.com/${{ github.repository }} main --follow-tags
Loading