node

sudo chown -R $USER /usr/local

 

Node was installed at

/usr/local/bin/node

npm was installed at

/usr/local/bin/npm

Make sure that /usr/local/bin is in your $PATH

 

which node;which npm;node -v ; npm -v;

export PATH="$PATH:/usr/local/git/bin:/usr/local/bin"

 

sudo chmod 777 /usr/local/lib

sudo chown -R whoami ~/.npm

sudo chown -R $USER /usr/local

 

npm config 

npm config set proxy http://proxy.company.com:8080

npm config set https-proxy http://proxy.company.com:8080

http://username:password@proxy.company.com:8080

 

.npmrc

 

npm --https-proxy=http://proxy.company.com:8080 -g install karma

to pass configuration parameters to npm as env variable, they must be prefixed with npm_config_

 

export npm_config_proxy http://proxy.company.com:8080

export npm_config_https_proxy http://proxy.company.com:8080

 

 

posted on 2014-04-16 19:24  grep  阅读(547)  评论(0)    收藏  举报