download-git-repo报错Error: ‘git clone‘ failed with status 128
download-git-repo报错Error: 'git clone' failed with status 128
·
在自制脚手架的时候,使用download-git-repo时报错信息如下:
Error: 'git clone' failed with status 128
at ChildProcess.<anonymous> (D:\frontendStudy\nodejsStudy\02-LEARN_CLI\node_modules\_git-clone@0.1.0@git-clone\index.js:33:22)
at ChildProcess.emit (node:events:513:28)
at maybeClose (node:internal/child_process:1091:16)
at Socket.<anonymous> (node:internal/child_process:449:11)
at Pipe.<anonymous> (node:net:313:12)
解决办法为:
在URL后加上#master并且去掉{clone:true}
download-git-repo('https://github.com/用户名/仓库名#master', project, err => {
console.log("-----", err)
});
更多推荐
已为社区贡献1条内容
所有评论(0)