-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
"yarn global add" doesn't globally install packages if .yarn-cache was restored #1151
Comments
I'm having the same issue, but with different circumstances. If I install a new version of node alongside an old version (using |
^ Me too! |
Same issue, using post:
- bash <(curl -s https://codecov.io/bash) is fast enouth (more than npm) and don't require to install any dependency |
yeah we are also having this same issue |
@andrewmclagan I had some issues like these after some debugging I realized that there were two versions of yarn. After that you must make sure that the bin folder is in the path variable —
|
More universal export (without username): |
@iryston where should i put this? |
@IzaGz it depends on your OS and shell. |
why so complicated? |
just out of curiosity, is there any reason we don't use the same path that npm uses? I was expecting yarn to be a drop in replacement (minus command names) for npm. |
Isn't there a cleaner solution? I installed |
workaround for windows:
|
yarn add global gulp-cli |
yarn has a bug on CircleCI: yarnpkg/yarn#1151
yarn has a bug on CircleCI: yarnpkg/yarn#1151
Do you want to request a feature or report a bug?
Bug
What is the current behavior?
If you restore .yarn-cache from another machine (e.g. on a CI system) that had a globally installed package, then running
yarn global add <pkg>
doesn't install the package on the new machine.If the current behavior is a bug, please provide the steps to reproduce.
Set up a circle.yml file that tells CircleCI to cache ~/.yarn-cache. Run a build and then run it again (make sure in the "Restore cache" step that
home/ubuntu/.yarn-cache
is restored).The second time around, even though
yarn global add codecov
runs successfully and sayssuccess Installed codecov@1.0.1 with binaries: codecov
, thecodecov
package is missing. It doesn't place anything in nvm's globalnode_modules
folder nor thebin
folder.What is the expected behavior?
yarn global add <pkg>
should reinstall the package. As a workaround, using npm oryarn global remove <pkg>
works fine.Please mention your node.js, yarn and operating system version.
Node 6.8.1 installed with nvm 0.31.0
Yarn 0.15.1 installed via curl + bash
Ubuntu 12.04 on CircleCI
The text was updated successfully, but these errors were encountered: