We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 060704d commit 18064d0Copy full SHA for 18064d0
scripts/publish-release.sh
@@ -4,6 +4,10 @@ set -euo pipefail
4
5
token="${NODE_AUTH_TOKEN:-${GITHUB_TOKEN:-${GH_TOKEN:-}}}"
6
7
+if [[ -z "$token" ]] && command -v gh >/dev/null 2>&1; then
8
+ token="$(gh auth token 2>/dev/null || true)"
9
+fi
10
+
11
if [[ -z "$token" ]]; then
12
echo "Missing auth token. Set NODE_AUTH_TOKEN, GITHUB_TOKEN, or GH_TOKEN."
13
exit 1
0 commit comments