【发布时间】:2018-10-16 07:42:59
【问题描述】:
我正在尝试从 Visual Studio 代码中的终端窗口安装 gulp-sass。
autoprefixer、concat 等其他依赖项安装没有问题,但 gulp-sass 一直给我这个错误。
> node-sass@4.9.0 install /usr/local/lib/node_modules/node-sass
> node scripts/install.js
sh: node: command not found
npm ERR! file sh
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! syscall spawn
npm ERR! node-sass@4.9.0 install: `node scripts/install.js`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the node-sass@4.9.0 install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
我在 Mac 上运行 VSC。
有什么帮助吗?顺便说一句,我完全是新手,没有编程背景,只是前端开发。
非常感谢
【问题讨论】:
-
您运行的安装命令是什么?
-
无法保存二进制文件 /home/hh/buildtool/udacity/wittr/node_modules/node-sass/vendor/linux-x64-64 : { 错误:EACCES: 权限被拒绝,mkdir '/home/ hh/buildtool/udacity/wittr/node_modules/node-sass/vendor 我有相同的版本和关闭类型的失败。我担心的是它适用于 docker
-
这对我有用:npm install --unsafe-perm=true