grunt icon indicating copy to clipboard operation
grunt copied to clipboard

grunt.file.read() breaks when path starts with a "#" symbol

Open artemgordinskiy opened this issue 10 years ago • 3 comments

I have tried to use this Grunt task, that uses Grunt's grunt.file.read() method, and noticed the following issue: When the given path starts with a "#" symbol (such as "#work/stuff"), the following error is thrown: Warning: Unable to read "undefined" file (Error code: ENOENT) The original issue with the task could be found here. Grunt 0.4.5 OS X 10.10.1

artemgordinskiy avatar Dec 15 '14 08:12 artemgordinskiy

This seems to be because Grunt uses an old version of glob. Glob interprets #'s as comments by default. This might be fixed by updating to a newer version of Glob.

keoghpe avatar Mar 23 '15 09:03 keoghpe

Turns out it's as a result of grunt using minimatch. You can stop this behaviour by including nocomment:true in your options for grunt.match.

keoghpe avatar Mar 23 '15 10:03 keoghpe

Is this still an issue with the latest version?

XhmikosR avatar Mar 23 '16 01:03 XhmikosR