Alibaba Cloud Source Python, npm, git, goproxy
Various ways to set the source are also relatively common, but I can't remember them at all, and it doesn't feel good to check them every time.
I just happened to find a treasure address , which seems to be quite complete. You can also look through this place to find the source in the future. By the way, I compiled a few and put them into a script.
Script content
#### python start ####
#### https://developer.aliyun.com/mirror/pypi?spm=a2c6h.13651102.0.0.28df1b11Iu49KV
mkdir -p ~/.pip
PYTHON_PIP=~/.pip/pip.conf
# echo "[global]" > $PYTHON_PIP
# echo "index-url = http://mirrors.aliyun.com/pypi/simple/" >> $PYTHON_PIP
# echo "" >> $PYTHON_PIP
# echo "[install]" >> $PYTHON_PIP
# echo "trusted-host=mirrors.aliyun.com" >> $PYTHON_PIP
echo "[global]
index-url = http://mirrors.aliyun.com/pypi/simple/
[install]
trusted-host=mirrors.aliyun.com
" > $PYTHON_PIP
#### python end ####
#### golang start ####
#### https://developer.aliyun.com/mirror/goproxy?spm=a2c6h.13651102.0.0.595d1b11ObQLXj
export GOPROXY=https://mirrors.aliyun.com/goproxy/
#### golang end ####
#### npm start ####
#### https://developer.aliyun.com/mirror/NPM?spm=a2c6h.13651102.0.0.595d1b11ObQLXj
npm config set registry https://registry.npmmirror.com
#### npm end ####
use
Paste the above content into various terminal environment files, such as bashrc/bash_profile and so on. . .