科尔多瓦插件相机防止git commit

时间:2018-10-04 15:30:46

标签: cordova cordova-plugins jsdoc2md

我的Ionic应用程序中有cordova-plugin-camera@4.0.3,并且在尝试使用git commit命令生成自己的文档时由于错误而阻止我运行jsdoc2md

$ git commit -m "x"

> cordova-plugin-camera@4.0.3 precommit /plugins/cordova-plugin-camera
> npm run gen-docs && git add README.md


> cordova-plugin-camera@4.0.3 gen-docs /plugins/cordova-plugin-camera
> jsdoc2md --template "jsdoc2md/TEMPLATE.md" "www/**/*.js" --plugin "dmd-plugin-cordova-plugin" > README.md

sh: jsdoc2md: command not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! cordova-plugin-camera@4.0.3 gen-docs: `jsdoc2md --template "jsdoc2md/TEMPLATE.md" "www/**/*.js" --plugin "dmd-plugin-cordova-plugin" > README.md`
npm ERR! spawn ENOENT
npm ERR! 
npm ERR! Failed at the cordova-plugin-camera@4.0.3 gen-docs script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/jeremylopez/.npm/_logs/2018-10-04T15_25_27_086Z-debug.log
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! cordova-plugin-camera@4.0.3 precommit: `npm run gen-docs && git add README.md`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the cordova-plugin-camera@4.0.3 precommit script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?

npm ERR! A complete log of this run can be found in:
npm ERR!     /.npm/_logs/2018-10-04T15_25_27_107Z-debug.log

husky - pre-commit hook failed (add --no-verify to bypass)

有什么主意如何克服这个错误?该应用程序内置在云中,因此我对软件包进行的任何本地更改都无济于事。

0 个答案:

没有答案