Is there a way to specify a working directory for yarn? This would be different then the --modules-folder option. Specifically, I'm trying to run the yarn install command from a location outside of the package location.
Similar to -C in git
-C
You can use --cwd like so yarn --cwd <path> <yarn command>. The order of arguments is important.
--cwd
yarn --cwd <path> <yarn command>
Example:
yarn --cwd ~/test_project/ dev
Because the following will not work:
yarn dev --cwd ~/test_project/
2.1m questions
2.1m answers
60 comments
57.0k users