I\'m trying to setup Yarn 0.17.9 in our environment but I have a problem with our registry. We are currently using two registries, official npmjs and our own registry on interna
You can make a .yarnrc
file in the root of the project and write this line in that file:
registry "https://registry.npmjs.org/"
This will act as a project specific repository.
Yarn doesn't have support --registry flag as npm but you can set up your registry in .yarnrc
If your .yarnrc is being ignored it can be copied out of the ~/.yarnrc using:
yarn config set registry http://registry.com/registry//
You can try set different registry in .npmrc
and .yarnrc
.
So for example:
In .npmrc
:
registry=https://yourcompany/
virtual/:_authToken=credentials
always-auth=true
always-auth=true needs to be the very last line in the file
And in .yarnrc
:
registry "https://registry.yarnpkg.com"
Then yarn add
/npm install
+ private-pakage/public-packge will work.