File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -79,11 +79,16 @@ jobs:
79
79
- name : Publish to npm
80
80
env :
81
81
NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
82
- NPM_CONFIG_REGISTRY : https://registry.npmjs.org
83
82
NPM_CONFIG_ALWAYS_AUTH : ' true'
84
83
run : |
85
- # Force registry + token for both npm and yarn
86
- printf "registry=https://registry.npmjs.org\n//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}\nalways-auth=true\n" > ~/.npmrc
84
+ # Force both npm and yarn to use npmjs and pick up the token
85
+ yarn config set registry https://registry.npmjs.org
86
+ npm config set registry https://registry.npmjs.org
87
+ printf "//registry.npmjs.org/:_authToken=${NODE_AUTH_TOKEN}\nalways-auth=true\n" > ~/.npmrc
88
+
89
+ # Sanity checks
90
+ echo "yarn registry: $(yarn config get registry)"
91
+ echo "npm registry: $(npm config get registry)"
87
92
88
93
TAG=$([ "$GITHUB_REF_NAME" = "master" ] && echo latest || echo "$GITHUB_REF_NAME")
89
94
yarn nx release publish --yes --tag "$TAG"
You can’t perform that action at this time.
0 commit comments