File tree Expand file tree Collapse file tree 1 file changed +3
-12
lines changed Expand file tree Collapse file tree 1 file changed +3
-12
lines changed Original file line number Diff line number Diff line change 1818 registry-url : ' https://registry.npmjs.org/'
1919
2020 - name : Check NPM Authentication
21- run : |
22- npm whoami --registry=https://registry.npmjs.org/ || echo "Not authenticated"
23-
24- - name : Check Publish Access
2521 env :
26- PACKAGE_NAME : " @segment/analytics-signals "
22+ NPM_TOKEN : ${{ secrets.NPM_TOKEN }}
2723 run : |
28- echo "Checking permissions for package: $PACKAGE_NAME"
29- curl -H "Authorization: Bearer $NPM_TOKEN" \
30- https://registry.npmjs.org/-/package/$PACKAGE_NAME/access || echo "No access or invalid token"
24+ curl -H "Authorization: Bearer ${NPM_TOKEN}" https://registry.npmjs.org/-/whoami || echo "Authentication failed"
25+
3126
32- - name : Dry-Run Publish
33- run : |
34- echo "//registry.npmjs.org/:_authToken=${NPM_TOKEN}" > ~/.npmrc
35- npm publish --dry-run || echo "Publish not allowed"
You can’t perform that action at this time.
0 commit comments