No need to invoke gh auth login when jenkins/GITHUB_TOKEN= is in use
Change-Id: I8c13f742ae28f577527ea15e5de7a595fa69ba6a
diff --git a/jjb/shell/github-release.sh b/jjb/shell/github-release.sh
index 5de6d03..da99794 100755
--- a/jjb/shell/github-release.sh
+++ b/jjb/shell/github-release.sh
@@ -703,7 +703,10 @@
else # jenkins
func_echo "$gh_cmd auth login ${login_args[@]} (ie: jenkins)"
- "$gh_cmd" auth login "${login_args[@]}"
+
+ # https://github.com/cli/cli/issues/2922#issuecomment-775027762
+ # When using GITHUB_TOKEN, there is no need to even run gh auth logi
+ # "$gh_cmd" auth login "${login_args[@]}"
fi
declare -i -g active_login=1 # signal logout needed