We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents e0ba7e8 + 9e3ee30 commit d4185e9Copy full SHA for d4185e9
script/try-publish
@@ -1,12 +1,12 @@
1
#!/bin/bash
2
set -e
3
# pwd
4
-package=$(jq .name package.json)
5
-version=$(jq .version package.json)
6
-published=$(npm info "$package@$version version")
+package=$(jq -r .name package.json)
+version=$(jq -r .version package.json)
+published=$(npm info $package@$version version)
7
if [[ "$version" = "$published" ]]; then
8
echo "⚠️ $package@$version is already published!"
9
else
10
- echo "📦 npm publish: $package@$version"
+ echo "📦 Publishing: $package@$version (published: $published)"
11
npm publish $@
12
fi
0 commit comments