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
17 changes: 15 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,13 @@ jobs:
run: |
for pkg_dir in npm/socket-patch-*/; do
echo "Publishing ${pkg_dir}..."
npm publish "./${pkg_dir}" --provenance --access public
npm publish "./${pkg_dir}" --provenance --access public || {
if npm view "@socketsecurity/$(basename "$pkg_dir")@${{ needs.version.outputs.version }}" version >/dev/null 2>&1; then
echo "Already published, skipping."
else
exit 1
fi
}
done

- name: Wait for npm registry propagation
Expand All @@ -304,7 +310,14 @@ jobs:
run: cp README.md npm/socket-patch/README.md

- name: Publish main package
run: npm publish ./npm/socket-patch --provenance --access public
run: |
npm publish ./npm/socket-patch --provenance --access public || {
if npm view "@socketsecurity/socket-patch@${{ needs.version.outputs.version }}" version >/dev/null 2>&1; then
echo "Already published, skipping."
else
exit 1
fi
}

pypi-publish:
needs: [version, build]
Expand Down
Loading