Nitishs-MacBook-Air:~niishanand $ cd myApp Nitishs-MacBook-Air:myApp nitishanand $ sudo离子平台添加android下载默认离子 资源
下载: https://github.com/driftyco/ionic-default-resources/archive/master.zip [=============================] 100%0.0s完成添加默认离子 资源为平台添加图标:android运行cordova平台 添加android添加android项目...为。创建Cordova项目 Android平台:路径:平台/ android包: com.ionicframework.myapp639143名称:myApp Android目标: android-21复制模板文件...项目已成功创建。 运行命令:
/Users/nitishanand/myApp/hooks/after_prepare/010_add_platform_class.js
/ Users / nitishanand / myApp错误:生成EACCES
at exports._errnoException(util.js:746:11)
在ChildProcess.spawn(child_process.js:1155:11) at Object.exports.spawn(child_process.js:988:9) at Object.exports.spawn(/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/cordova/superspawn.js:100:31) at runScriptViaChildProcessSpawn(/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/hooks/HooksRunner.js:188:23) at runScript(/usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/hooks/HooksRunner.js:131:16) at /usr/local/lib/node_modules/cordova/node_modules/cordova-lib/src/hooks/HooksRunner.js:114:20 在_fulfilled(/usr/local/lib/node_modules/cordova/node_modules/q/q.js:787:54) at self.promiseDispatch.done(/usr/local/lib/node_modules/cordova/node_modules/q/q.js:816:30) 在Promise.promise.promiseDispatch(/usr/local/lib/node_modules/cordova/node_modules/q/q.js:749:13)
答案 0 :(得分:8)
尝试
chmod 755 /Users/nitishanand/myApp/hooks/after_prepare/010_add_platform_class.js
它对我有用。