-
-
Notifications
You must be signed in to change notification settings - Fork 298
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
Convenience fs
methods
#824
Comments
Same with |
👍 |
Sorry for the late answer, but here it is! I considered this when designing this initial API and decided to not do anything about it at this point. There's in my opinion a pretty high complexity cost to automatically combine paths in files methods. The main issue here is being consistent in our API. As it's very easy to see how useful it would be in the case of copy, it doesn't really make sense for the read/write methods. Can we really assume someone would always want to read from their template folder? Probably not. Considering this, it would be very inconsistent to have different behavior between our file system helpers. Without a better idea, I decided to go the verbose paths for now. I hoped globbing support (e.g. An option I also considered is to rename |
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 |
This is a very common operation, but it's very verbose.
Would be nice to have a yeoman specific convenience wrapper that called
templatePath
anddestinationPath
for you:Where
copyFoo
gets a better name.Same with
copyTpl
.Example of how verbose it gets:
sindresorhus/generator-gulp-plugin-boilerplate@d7503c0#diff-2018087f584c4398b5c3a23fc0e5f9dbR53
The text was updated successfully, but these errors were encountered: