File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -25,6 +25,16 @@ type gh &>/dev/null || ~/ci/.circle/install_gh
2525export GH_TOKEN=${MACHINE_PASSWORD}
2626source ~ /ci/tools/functions.sh
2727
28+ DEFAULT_BRANCH=$( _gh_default_branch)
29+ # Give a good error message after the first use of github API in this script.
30+ if $? ! = 0; then
31+ echo " Error retrieving data with github graphql API."
32+ echo " The GitHub PAT might need to be regenerated:"
33+ echo " https://github.com/settings/tokens/new?scopes=public_repo&description=CircleCI%3A%20stackstorm-${PACK_NAME} "
34+ else
35+ echo " GitHub PAT is active."
36+ fi
37+
2838# TODO: figure out how to make deploy.py rebuild the index.
2939# python ~/packs/.circle/deploy.py pack.yaml "${CIRCLE_PROJECT_REPONAME}"
3040
5868 fi
5969done
6070
61- DEFAULT_BRANCH=$( _gh_default_branch)
6271# Afer pushing the version, make sure we check out the latest commit
6372# This is important so index reflects latest changes
6473git checkout ${DEFAULT_BRANCH}
Original file line number Diff line number Diff line change @@ -155,7 +155,7 @@ def get_available_versions():
155155 if proc .returncode != 0 :
156156 sys .exit (
157157 "Error retrieving data with github graphql API.\n "
158- "The Github PAT might need to be regenerated:\n "
158+ "The GitHub PAT might need to be regenerated:\n "
159159 "https://github.com/settings/tokens/new?scopes=public_repo"
160160 "&description=CircleCI%3A%20stackstorm-" + ACTIVE_PACK_NAME
161161 )
You can’t perform that action at this time.
0 commit comments