试图使一个咕噜咕噜的项目工作

时间:2015-02-24 19:20:01

标签: sass gruntjs npm zurb-foundation

我是咕噜咕噜咕噜咕噜咕噜咕噜咕噜咕噜咕噜咕噜咕噜咕噜咕噜咕噜我已经了解它是什么,有什么好处,我已经按照这个快速入门使其在我的机器上工作

https://github.com/olefredrik/foundationpress

一切正常,直到行:

npm install && bower install && grunt build

以下是我得到的错误:

npm WARN locking Error: EACCES, open '/Users/to3ky/.npm/_locks/node-sass-f213edefcf6a8ef5.lock'
npm WARN locking     at Error (native)
npm WARN locking  /Users/to3ky/.npm/_locks/node-sass-f213edefcf6a8ef5.lock failed { [Error: EACCES, open '/Users/to3ky/.npm/_locks/node-sass-f213edefcf6a8ef5.lock']
npm WARN locking   errno: -13,
npm WARN locking   code: 'EACCES',
npm WARN locking   path: '/Users/to3ky/.npm/_locks/node-sass-f213edefcf6a8ef5.lock' }
npm ERR! Darwin 13.4.0
npm ERR! argv "node" "/usr/local/bin/npm" "install"
npm ERR! node v0.12.0
npm ERR! npm  v2.5.1

npm ERR! Attempt to unlock /Applications/XAMPP/xamppfiles/htdocs/aaa/studiohaupt/wp-content/themes/atheme2/node_modules/node-sass, which hasn't been locked
npm ERR! 
npm ERR! If you need help, you may report this error at:
npm ERR!     <http://github.com/npm/npm/issues>

npm ERR! Please include the following file with any support request:
npm ERR!     /Applications/XAMPP/xamppfiles/htdocs/aaa/studiohaupt/wp-content/themes/atheme2/npm-debug.log

但我不知道它是什么意思。 我是新来的咆哮bower npm所以我很难在这一步潜入它自己。

如果我运行grunt

Loading "sass.js" tasks...ERROR
>> Error: Cannot find module 'node-sass'

我在MAC上,我使用XAMPP,我正潜入黑暗中。

2 个答案:

答案 0 :(得分:0)

这应该可以解决您的问题:

sudo chown -R `whoami` ~/.npm
sudo chown -R `whoami` /usr/local/lib/node_modules
sudo chown -R `whoami` /usr/local

答案 1 :(得分:-1)

如果您使用的是OSX,则应在所有命令行命令之前添加SUDO