Created
June 29, 2014 10:16
-
-
Save tangzhen/1419c3eee991664bc02d to your computer and use it in GitHub Desktop.
Switch NodeJS and Ruby Gem to China Taobao mirror
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# switch npm | |
echo '\n#alias for cnpm\nalias cnpm="npm --registry=registry.npm.taobao.org \ | |
--cache=$HOME/.npm/.cache/cnpm \ | |
--disturl=http://npm.taobao.org/dist \ | |
--userconfig=$HOME/.cnpmrc"' >> ~/.zshrc && source ~/.zshrc | |
#switch Ruby gem | |
gem sources --remove https://rubygems.org/ | |
gem sources -a https://ruby.taobao.org/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment