gulp-fontcustom
gulp-fontcustom copied to clipboard
Weird ENOENT error
~/SomeProject/app $ gulp icons
[gulp] Using gulpfile ~/SomeProject/app/gulpfile.js
[gulp] Starting 'icons'...
/home/ale/SomeProject/app/node_modules/gulp-fontcustom/node_modules/child-process-promise/node_modules/q/q.js:126
throw e;
^
Error: Can't list "./___tmp___": ENOENT, readdir './___tmp___'
Config looks like so (nothing unusual here):
var gulp = require('gulp'),
fontcustom = require('gulp-fontcustom');
gulp.task('icons', function() {
return gulp.src("src/icons/*.svg")
.pipe(fontcustom({
font_name: 'MaterialIcons'
}))
.pipe(gulp.dest("www/icons/"));
});
What could have gone wrong?
Looks like deleting .fontcustom-manifest.json helped around this. The file probably was corrupted in some way.
It still would be better to pass any error output from fontcustom, since it would have given a hint:
error Couldn't parse `.fontcustom-manifest.json`. Fix any invalid JSON or delete the file to start from scratch.
Same here, but I don't have a .fontcustom-manifest.json file to delete.
The problem is that there is no error output from exec, from fontcustom process run.
UPD: so, I've debugged that stuff and figured out that it is fontcustom binary that swallow errors. So, there is no straightforward way to fix it in this plugin.
If you face some issue I'd propose to run the command, generated in plugin, directly and see the output.
I've merged #8 to master, feel free to pull down and verify.
Can you update npm package with fix?
@kikar Done! https://www.npmjs.com/package/gulp-fontcustom