icomoon-build icon indicating copy to clipboard operation
icomoon-build copied to clipboard

Bad error message when no path is passed for CSS output

Open tambry opened this issue 4 years ago • 1 comments

Using Node 12.6.0:

> npx icomoon-build --css -p .\res\icons.json --fonts dist/
internal/fs/utils.js:426
    throw new ERR_INVALID_ARG_TYPE(propName, ['string', 'Buffer', 'URL'], path);
    ^

TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be one of type string, Buffer, or URL. Received type boolean
    at Object.openSync (fs.js:439:10)
    at Object.writeFileSync (fs.js:1206:35)
    at <my project root>\node_modules\icomoon-build\lib\cli.js:23:20
    at Array.forEach (<anonymous>)
    at <my project root>\node_modules\icomoon-build\lib\cli.js:17:70
    at <my project root>\node_modules\icomoon-build\lib\icomoon.js:104:9
    at ChildProcess.exithandler (child_process.js:288:7)
    at ChildProcess.emit (events.js:203:13)
    at maybeClose (internal/child_process.js:1021:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:283:5)

tambry avatar Jul 09 '19 09:07 tambry