node.js v4.2.2 安裝time模塊是出錯node
gyp WARN EACCES user "root" does not have permission to access the dev dir "/home/countly/nodejs/lib/node_modules/time/.node-gyp/0.10.36"express
gyp WARN EACCES attempting to reinstall using temporary dev dir "/home/countly/nodejs/lib/node_modules/time/.node-gyp"npm
百度了很久資料,終於發現瞭解決辦法,特此記錄ide
sudo npm install time -g --unsafe-perm spa
增長了--unsafe-perm generator
順便寫一下新頒佈 express 的安裝it
npm -g install express io
npm -g install express-generatorclass