thx / rap2-dolores

MIT License
610 stars 254 forks source link

前端服务启动报错 #10

Closed zhouruizhong closed 6 years ago

zhouruizhong commented 6 years ago

rap2-dolores@1.0.0 watch-css /usr/local/rap2-dolores

npm run build-css && node-sass src/ -o src/ --watch --recursive

rap2-dolores@1.0.0 build-css /usr/local/rap2-dolores node-sass src/ -o src/

fs.js:904 return binding.readdir(pathModule._makeLong(path), options.encoding); ^

Error: ENOENT: no such file or directory, scandir '/usr/local/rap2-dolores/node_modules/node-sass/vendor' at Object.fs.readdirSync (fs.js:904:18) at Object.getInstalledBinaries (/usr/local/rap2-dolores/node_modules/node-sass/lib/extensions.js:124:13) at foundBinariesList (/usr/local/rap2-dolores/node_modules/node-sass/lib/errors.js:20:15) at foundBinaries (/usr/local/rap2-dolores/node_modules/node-sass/lib/errors.js:15:5) at Object.module.exports.missingBinary (/usr/local/rap2-dolores/node_modules/node-sass/lib/errors.js:45:5) at module.exports (/usr/local/rap2-dolores/node_modules/node-sass/lib/binding.js:15:30) at Object. (/usr/local/rap2-dolores/node_modules/node-sass/lib/index.js:14:35) at Module._compile (module.js:635:30) at Object.Module._extensions..js (module.js:646:10) at Module.load (module.js:554:32) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! rap2-dolores@1.0.0 build-css: node-sass src/ -o src/ npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the rap2-dolores@1.0.0 build-css 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! /root/.npm/_logs/2017-12-13T13_56_29_831Z-debug.log npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! rap2-dolores@1.0.0 watch-css: npm run build-css && node-sass src/ -o src/ --watch --recursive npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the rap2-dolores@1.0.0 watch-css 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! /root/.npm/_logs/2017-12-13T13_56_29_878Z-debug.log ERROR: "watch-css" exited with 1. npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! rap2-dolores@1.0.0 start: npm-run-all -p watch-css start-js

youjianglong commented 6 years ago

我安装也遇到同样的错误

zhouruizhong commented 6 years ago

已解决,npm down 包不完整,切换到国内镜像(淘宝镜像)就没问题了,安装好cnpm 就可以了