File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -137,38 +137,12 @@ jobs:
137137 with :
138138 node-version : ${{ env.node-version }}
139139
140- # install dependencies and run semantic-release
141-
142140 - run : npm i -g semantic-release @semantic-release/{git,exec,changelog}
143-
144- - name : Verify GITHUB_TOKEN is set
145- run : |
146- if [ -z "$GITHUB_TOKEN" ]; then
147- echo "::error::GITHUB_TOKEN is not set. Please add GITHUB_TOKEN secret to the repository." >&2
148- exit 1
149- fi
150- env :
151- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
152-
153- - name : Verify GITHUB_TOKEN validity with GitHub API
154- run : |
155- status=$(curl -s -o /dev/null -w "%{http_code}" -H "Authorization: token $GITHUB_TOKEN" https://api.github.com/user)
156- echo "Token validation status: $status"
157- if [ "$status" -ne 200 ]; then
158- echo "::error::GITHUB_TOKEN is invalid or lacks permissions (HTTP $status)"
159- exit 1
160- else
161- echo "GITHUB_TOKEN is valid "
162- fi
163- env :
164- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
165-
166-
167141 - name : Run semantic-release
168142 run : semantic-release
169143 if : ${{ !env.ACT }}
170144 env :
171- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
145+ GH_TOKEN : ${{ secrets.GH_TOKEN }}
172146 deploy :
173147 name : Deploy to dev CDN
174148 runs-on : ubuntu-latest
You can’t perform that action at this time.
0 commit comments