You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
this.contextRoot contains the path to where the yo CLI was executed from. When yo is wrapped in an npm script (such as npm run generate), this.contextRoot should be the value of process.env.CWD_INIT.
Current behavior
When yo is wrapped in an npm script, this.contextRoot contains the path to the project root.
The text was updated successfully, but these errors were encountered:
I am facing the same "issue". I've hacked around it by altering my npm run script to change directories prior to calling yo, but it would be great if yo was just smart enough to do this on its own.
This is still an issue for me. Trying to use yeoman in a monorepo and everything is always copied to the root, never the current folder. How did you solve this @stevenvachon ?
Type of issue
Feature request or bug, not sure.
My environment
10.14
10.11.0
6.4.1
2.0.5
Expected behavior
this.contextRoot
contains the path to where theyo
CLI was executed from. Whenyo
is wrapped in an npm script (such asnpm run generate
),this.contextRoot
should be the value ofprocess.env.CWD_INIT
.Current behavior
When
yo
is wrapped in an npm script,this.contextRoot
contains the path to the project root.The text was updated successfully, but these errors were encountered: