Closed artch closed 10 years ago
I thought path.sep
should be handling this for us...
path.sep
indicates which one is used in OS the script is running on. But main
field of the particular component contains separators in that format which was chosen by the component's author, it is set by him manually in bower.json
config. And therefore it can be in any format, or even in mixed format.
Thanks for merging.
That makes sense, havn't thought about it before. npm package published. Thank you!
Wow, too fast... I am preparing another PR with one more config feature at the moment. :)
Keep them coming!
2014-04-09 23:08 GMT+08:00 Artem Chivchalov notifications@github.com:
Wow, too fast... I am preparing another PR with one more config feature at the moment. :)
Reply to this email directly or view it on GitHubhttps://github.com/curist/grunt-bower/pull/21#issuecomment-39975186 .
Bower components may have file paths in
main
field in different formats, including\
and/
path separators in different cases. We can't always rely just onpath.sep
when splitting the file name prior to copying. Broken use case: with current version ofgrunt-bower
copying of Twitter Bootstrap in Windows environment doesn't work, such an error is thrown:Changing the path separator to more common regexp rather than
path.sep
solves the problem.