-
Notifications
You must be signed in to change notification settings - Fork 52
Open
Description
Hi all,
It seems the grunt rev section in its current form can't distinguish between a directory ending in ".js" and a .js file. Grunt-rev (and subsequently usemin) will fail with
Warning: Unable to read "dist/public/bower_components/spin.js" file (Error code:
EISDIR). Use --force to continue.
Aborted due to warnings.
In the below Gruntfile.js section, I fixed the problem by singling out each .js/ directory (spin.js is a project name and a .js file, for example) and excluding it. If you can tell me a more general way to do it by regex I would appreciate it.
// Renames files for browser caching purposes
rev: {
dist: {
files: {
src: [
'<%= yeoman.dist %>/public/**/*.js',
'<%= yeoman.dist %>/public/**/*.css',
'<%= yeoman.dist %>/public/assets/images/{,*/}*.{png,jpg,jpeg,gif,webp,svg}',
'<%= yeoman.dist %>/public/assets/fonts/{,*/}*.ttf',
'!<%= yeoman.dist %>/public/bower_components/openlayers/tests/node.js',
'!<%= yeoman.dist %>/public/bower_components/spin.js'
]
}
}
},
MagRelo
Metadata
Metadata
Assignees
Labels
No labels