npm i运行命令 - 失败了吗?

时间:2018-06-19 09:44:36

标签: node.js cordova ionic-framework npm ionic3

创建文件夹并在离子

中运行新应用程序时,所有方式都显示错误
  

我安装了推荐版本的node.js,我从ionicframework.com安装了离子,但我无法创建应用程序:

     

MBP-di-Carlo:ionic-workspace carlolomello $ sudo ionic start myApp blank密码:

     

?目录myApp包含可能冲突的文件。你想用这个新项目写这个目录吗?是✔创建目录./myApp - 完成! ✔下载并提取空白启动器 - 完成!

     

?您想将新应用与Cordova集成到目标iOS和Android吗?是✔个性化ionic.config.json和package.json - 完成!

     

离子集成启用cordova--quiet✔下载集成cordova - 完成! ✔将集成文件复制到项目 - 完成! [确定]添加了cordova集成!

     

安装依赖项可能需要几分钟时间。

     

✨IONIC DEVAPP✨

     

使用我们快速的设备上测试移动应用Ionic DevApp加速开发    在没有Native SDK的iOS和Android上进行测试     LiveReload用于即时风格和JS更新

     

️ - >安装DevApp:https:// bi t .ly / ionic-dev-app< -

     

npmi✖运行命令 - 失败! [错误]运行npm i时出错(退出代码1):

npm WARN registry Unexpected warning for https://registry.npmjs.org/: Miscellaneous Warning EPROTO: request to 
    https://registry.npmjs.org/esmangle-evaluator failed, reason: write EPROTO 139653691287360:error:1414D17A:SSL 
    routines:tls12_check_peer_sigalg:wrong curve:../deps/openssl/openssl/ssl/t1_lib.c:1097:\n
    npm WARN registry Using stale package data from https://registry.npmjs.org/ due to a request error during 
    revalidation.

    > node-sass@4.9.0 install /home/systica/helloWorld/node_modules/node-sass
    > node scripts/install.js

    Unable to save binary /home/systica/helloWorld/node_modules/node-sass/vendor/linux-x64-57 : { Error: EACCES: 
    permission denied, mkdir '/home/systica/helloWorld/node_modules/node-sass/vendor'
         at Object.fs.mkdirSync (fs.js:885:18)
         at sync (/home/systica/helloWorld/node_modules/mkdirp/index.js:71:13)
         at Function.sync (/home/systica/helloWorld/node_modules/mkdirp/index.js:77:24)
         at checkAndDownloadBinary (/home/systica/helloWorld/node_modules/node-sass/scripts/install.js:114:11)
         at Object.<anonymous> (/home/systica/helloWorld/node_modules/node-sass/scripts/install.js:157:1)
         at Module._compile (module.js:652:30)
         at Object.Module._extensions..js (module.js:663:10)
         at Module.load (module.js:565:32)
         at tryModuleLoad (module.js:505:12)
         at Function.Module._load (module.js:497:3)
       errno: -13,
       code: 'EACCES',
       syscall: 'mkdir',
       path: '/home/systica/helloWorld/node_modules/node-sass/vendor' }

    > uglifyjs-webpack-plugin@0.4.6 postinstall /home/systica/helloWorld/node_modules/uglifyjs-webpack-plugin
    > node lib/post_install.js


    > node-sass@4.9.0 postinstall /home/systica/helloWorld/node_modules/node-sass
    > node scripts/build.js

    Building: /usr/bin/node /home/systica/helloWorld/node_modules/node-gyp/bin/node-gyp.js rebuild --verbose 
    --libsass_ext= --libsass_cflags= --libsass_ldflags= --libsass_library=
    gyp info it worked if it ends with ok
    gyp verb cli [ '/usr/bin/node',
    gyp verb cli   '/home/systica/helloWorld/node_modules/node-gyp/bin/node-gyp.js',
    gyp verb cli   'rebuild',
    gyp verb cli   '--verbose',
    gyp verb cli   '--libsass_ext=',
    gyp verb cli   '--libsass_cflags=',
    gyp verb cli   '--libsass_ldflags=',
    gyp verb cli   '--libsass_library=' ]
    gyp info using node-gyp@3.7.0
    gyp info using node@8.11.3 | linux | x64
    gyp verb command rebuild []
    gyp verb command clean []
    gyp verb clean removing "build" directory
    gyp verb command configure []
    gyp verb check python checking for Python executable "python2" in the PATH
    gyp verb `which` succeeded python2 /usr/bin/python2
    gyp verb check python version `/usr/bin/python2 -c "import platform; print(platform.python_version());"` 
    returned: "2.7.12\n"
    gyp verb get node dir no --target version specified, falling back to host node version: 8.11.3
    gyp verb command install [ '8.11.3' ]
    gyp verb install input version string "8.11.3"
    gyp verb install installing version: 8.11.3
    gyp verb install --ensure was passed, so won't reinstall if already installed
    gyp verb install version is already installed, need to check "installVersion"
    gyp verb got "installVersion" 9
    gyp verb needs "installVersion" 9
    gyp verb install version is good
    gyp verb get node dir target node version installed: 8.11.3
    gyp verb build dir attempting to create "build" dir: /home/systica/helloWorld/node_modules/node-sass/build
    gyp ERR! configure error 
    gyp ERR! stack Error: EACCES: permission denied, mkdir '/home/systica/helloWorld/node_modules/node-sass/build'
    gyp ERR! System Linux 4.4.0-127-generic
    gyp ERR! command "/usr/bin/node" "/home/systica/helloWorld/node_modules/node-gyp/bin/node-gyp.js" "rebuild" 
    "--verbose" "--libsass_ext=" "--libsass_cflags=" "--libsass_ldflags=" "--libsass_library="
    gyp ERR! cwd /home/systica/helloWorld/node_modules/node-sass
    gyp ERR! node -v v8.11.3
    gyp ERR! node-gyp -v v3.7.0
    gyp ERR! not ok 
    Build failed with error code: 1
    npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules/fsevents):
    npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted 
    {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})

    npm ERR! code ELIFECYCLE
    npm ERR! errno 1
    npm ERR! node-sass@4.9.0 postinstall: `node scripts/build.js`
    npm ERR! Exit status 1
    npm ERR! 
    npm ERR! Failed at the node-sass@4.9.0 postinstall script.
    npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

    npm ERR! A complete log of this run can be found in:
    npm ERR!     /home/systica/.npm/_logs/2018-06-19T09_42_50_820Z-debug.log

0 个答案:

没有答案