Skip to content
Snippets Groups Projects
Commit 9e59fc9a authored by Reiter, Christoph's avatar Reiter, Christoph :snake:
Browse files

Write npmrc file in CI only

locally yarn would fail because it can't expand the env var because it
is usually missing:

error An unexpected error occurred: "Failed to replace env in config: ${NPM_TOKEN}"
parent e98b3ee3
No related branches found
No related tags found
No related merge requests found
Pipeline #14673 failed
......@@ -23,6 +23,7 @@ publish:
- publish
- master
script:
- echo '//registry.npmjs.org/:_authToken=${NPM_TOKEN}' > .npmrc
- sudo npm install --global can-npm-publish
- yarn config set registry https://registry.npmjs.org/
- yarn config set cache-folder "$CI_PROJECT_DIR/_yarn_cache"
......
//registry.npmjs.org/:_authToken=${NPM_TOKEN}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment