2017-07-05 15 views
0

當我跑當我運行ion build ios命令時,Permission denied error?

離子構建IOS

我碰到下面的錯誤。

SH:/Users/imac/Documents/TGF_IOS/node_modules/.bin/ionic-app-scripts:權限被拒絕

npm ERR! Darwin 15.6.0 
npm ERR! argv "/usr/local/bin/node" "/usr/local/bin/npm" "run" "ionic:build" "--" 
npm ERR! node v6.10.2 
npm ERR! npm v3.10.10 
npm ERR! code ELIFECYCLE 
npm ERR! [email protected] ionic:build: `ionic-app-scripts build` 
npm ERR! Exit status 126 
npm ERR! 
npm ERR! Failed at the [email protected] ionic:build script 'ionic-app-scripts build'. 
npm ERR! Make sure you have the latest version of node.js and npm installed. 
npm ERR! If you do, this is most likely a problem with the ionic-hello-world package, 
npm ERR! not with npm itself. 
npm ERR! Tell the author that this fails on your system: 
npm ERR!  ionic-app-scripts build 
npm ERR! You can get information on how to open an issue for this project with: 
npm ERR!  npm bugs ionic-hello-world 
npm ERR! Or if that isn't available, you can get their info via: 
npm ERR!  npm owner ls ionic-hello-world 
npm ERR! There is likely additional logging output above. 

npm ERR! Please include the following file with any support request: 
npm ERR!  /Users/imac/Documents/TGF_IOS/npm-debug.log 

任何幫助將不勝感激..提前 感謝

回答

0

最後我得到了解決方案。

第一步檢查您是否有權限(讀/寫)到項目文件夾。

其次,使用sudo運行此命令,

sudo npm install @ionic/[email protected] --save-dev 

這將安裝最新的應用程序,腳本和無線本地環路解決問題。

相關問題