We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
问题描述:
我们有个生态组件结构大致如下:
在Windows下安装该组件,直接报错,我调试了下,发现windows下下载组件的zip解压会将目录合并,如下:
进一步调试发现,是因为decompress 0.2.3在windows下有bug:
kevva/decompress#14
将decompress升级到3.0.0版本
node_modules/ares-command-install/lib/package.js修改下载逻辑:
//var reader = fs.createReadStream(ball).on('error', done), // writer = reader.pipe(decompress({ // ext: ext, // path: archive, // strip: 1 // })).on('error', done).on('close', done); // //function done(err) { // //fs.unlinkSync(ball); // reader.removeListener('error', done); // writer.removeListener('error', done); // writer.removeListener('close', done); // if (err) { // rimraf.sync(archive); // return callback.call(that, err); // } // that.trim(archive, dest, callback); //} new decompress({mode: '755'}) .src(ball) .dest(archive) .use(decompress.zip({strip: 1})) .run(function(error){ if ( error ) { console.log( error ); } else { console.log( "ok" ); that.trim(archive, dest, callback); } });
暂时问题解决,请关注下,代码修改有没有问题。
The text was updated successfully, but these errors were encountered:
@myseawp
代码应该没问题,上面的 ares-command-install 是你基于scrat封装的新工具么?这个bug修复是需要在scrat中处理还是你在你的ares-command-install中已经解决了?
ares-command-install
Sorry, something went wrong.
ares-command-install 是我们自己封装的工具,目前按这样的方式问题已经解决,来给你汇报下, 我看到现在scrat里使用的scrat-command-install,使用的也是decompress 0.2.3
应该也会有同样的问题
@myseawp 好,我也更新一下,多谢提醒
@fouber 这个更新没? 要不要我这边处理?
No branches or pull requests
问题描述:
我们有个生态组件结构大致如下:
在Windows下安装该组件,直接报错,我调试了下,发现windows下下载组件的zip解压会将目录合并,如下:
进一步调试发现,是因为decompress 0.2.3在windows下有bug:
kevva/decompress#14
将decompress升级到3.0.0版本
node_modules/ares-command-install/lib/package.js修改下载逻辑:
暂时问题解决,请关注下,代码修改有没有问题。
The text was updated successfully, but these errors were encountered: