Reputation: 5569
I've been using yarn with a private registry in the past - however, the registry has now shut down and I want to use yarn with the official registry.
Whatever I do, yarn always seems to want to connect to the old registry and there's simply no way of making it use the new one. I've already tried:
yarn config set registry https://registry.yarnpkg.com/
~/.npmrc
or ~/.yarnrc
yarn cache clean
No matter what I do, yarn still tries to connect to the old registry on every install and I have no idea where yarn is getting that from...
any ideas?
Upvotes: 22
Views: 11108
Reputation: 7550
Running yarn add
with --verbose
will tell you which .yarnrc
files are being picked up. These shouldn't include the old registry.
So run yarn add <your-package> --verbose
and check the .yarnrc
files found for any mention of the old registry.
Upvotes: 2
Reputation: 3166
Remove your global yarn.lock
rm ~/.config/yarn/global/yarn.lock
and then
yarn config set registry https://registry.yarnpkg.com/
Upvotes: 20