1
0
mirror of https://github.com/lancedikson/bowser synced 2026-02-09 17:40:09 +00:00

fix: attemp to resolve NPM publish issues

This commit is contained in:
naorpeled 2026-02-07 19:12:34 +02:00
parent 8f9badd27f
commit e2318ef12d

View File

@ -43,23 +43,4 @@ jobs:
- run: npm version $RELEASE_VERSION --no-git-tag-version
- run: npm run build
- name: Publish to npm
run: |
max_attempts=5
attempt=1
while [ $attempt -le $max_attempts ]; do
echo "Attempt $attempt of $max_attempts..."
if npm publish --access public; then
echo "Successfully published!"
break
else
if [ $attempt -eq $max_attempts ]; then
echo "Failed to publish after $max_attempts attempts"
exit 1
fi
echo "Publish failed, waiting before retry..."
sleep_time=$((attempt * 30))
echo "Waiting ${sleep_time} seconds before retry..."
sleep $sleep_time
attempt=$((attempt + 1))
fi
done
run: npm publish