Skip to content

[Feature] yarn npm publish get token from environment variable #2985

Answered by merceyz
nodece asked this question in Q&A
Discussion options

You must be logged in to vote

Yarn supports loading settings from the environment, it's one of the first things documented here https://yarnpkg.com/configuration/yarnrc, for this specific case it would be

YARN_NPM_AUTH_TOKEN="<token>" yarn npm publish

https://yarnpkg.com/configuration/yarnrc#npmAuthToken

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by nodece
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #2984 on June 04, 2021 07:01.