Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sourceRoot method joins the path given with destinationRoot instead of sourceRoot #1085

Closed
ozeno opened this issue Jul 26, 2018 · 5 comments
Closed
Labels

Comments

@ozeno
Copy link

ozeno commented Jul 26, 2018

No description provided.

@SBoudrias
Copy link
Member

Actually sourceRoot isn't a join method. It's replacing the folder used as the source. In 99% of the cases, you don't want/need to use this method at all. Use destinationPath() and templatePath() if you want to generate paths.

@ozeno
Copy link
Author

ozeno commented Jul 30, 2018

As far as I understand sourceRoot('src') should set the source_root path to 'source_root/src' but it sets the source_root to 'destination_root/src' instead.

@dt-rush
Copy link

dt-rush commented Nov 22, 2018

This is also tracked by #1070

@g1eny0ung
Copy link

Same problem for me. I have to change the _sourceRoot to make it work as expected.

this._sourceRoot = path.resolve(__dirname, '../templates')

@github-actions
Copy link
Contributor

This issue is stale because it has been open 15 days with no activity. Remove stale label or comment or this will be closed in 5 days

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants