Closed cbuteau closed 8 years ago
I tried editing the code and dumping the stack and this was all I got.
var onError = function(err) {
console.error(err)
// alteration.
console.error(err.stack)
done(new gutil.PluginError('gulp-crx', err))
}
[15:39:42] Starting 'package'...
[15:39:42] Finished 'package' after 41 ms
{ [Error: ENOTDIR: not a directory, scandir 'D:\chrome\listOfLists\dist\delete.png']
errno: -4052,
code: 'ENOTDIR',
syscall: 'scandir',
path: 'D:\\chrome\\listOfLists\\dist\\delete.png' }
Error: ENOTDIR: not a directory, scandir 'D:\chrome\listOfLists\dist\delete.png'
at Error (native)
I also tried upgrading to the lateset node because it seems to be a problem with fs. You use crx which uses wrench which uses fs.
$ node --version
v5.10.1
I am puzzled. I considered using crx directly but I saw what you were doing for favors and followed my code analysis to wrench and fs which seemed to be the real problem.
Sorry, I do not have any developer Windows machine to see if that's a platform or configuration issue. I would be glad if you try to debug what's going on. See the index.js
file, there is not much this plugin is doing.
I debugged it pretty deep and it seemed to be some weirdness with fs itself. I used node-inspector and the base crx module uses promises so it was even more asynchronous.
I opened a bug on crx itself...but no one responded. https://github.com/oncletom/crx/issues/55
I am now investigating calling crx directly from the commandline. But that will prove more difficult to automate from gulp.
I'll close the bug since I don't think I can resolve it.
I just tried your package on windows and it fails with ENOTDIR on a file.
This is the code. I found the easiest way was to create a staging area for the files I wanted. (dist)