系统环境

Windows,安装了msys2,windows和msys2都安装了python,且版本比较多,使用shell/bash聚合工具conemu64

配置方案

配置msys2环境用户目录下的.bashrc,增加alias如下,日常通过conemu64模拟出来的msys2终端工具调用:

# msys2 python 2.7
alias mpy="/usr/bin/python2.exe"
alias mpip="/mingw64/bin/pip2.exe"
alias mei="/mingw64/bin/easy_install-2.7.exe"
# msys2 python 3.4
alias mpy3="/usr/bin/python3.exe"
alias mpip3="/mingw64/bin/pip3.exe"
alias mei3="/mingw64/bin/easy_install-3.5.exe"
# windows python 2.7
alias wpy="/c/Develop/Python27/python.exe"
alias wpip="/c/Develop/Python27/Scripts/pip2.exe"
alias wei="/c/Develop/Python27/Scripts/easy_install-2.7.exe"
alias wip="/c/Develop/Python27/Scripts/ipython.exe"
# pypy 2.7
alias pypy="/c/Develop/pypy/pypy2-v5.6.0-win32/pypy.exe"
alias wpip="/c/Develop/pypy/pypy2-v5.6.0-win32/bin/pip2.7.exe"
alias wei="/c/Develop/pypy/pypy2-v5.6.0-win32/bin/easy_install-2.7.exe"
# windows python 3.4
alias wpy3="/c/Develop/Python34/python.exe"
alias wpip3="/c/Develop/Python34/Scripts/pip3.4.exe"
alias wei3="/c/Develop/Python34/Scripts/easy_install-3.4.exe"
alias wip3="/c/Develop/Python34/Scripts/ipython.exe"
# Anaconda2
alias apy="/C/Develop/Anaconda2/python.exe"
alias apip="/c/Develop/Anaconda2/Scripts/pip.exe"
alias aei="/c/Develop/Anaconda2/Scripts/easy_install.exe"
alias aip="/c/Develop/Anaconda2/Scripts/ipython.exe"
# Anaconda3
alias apy3="/C/Develop/Anaconda3/python.exe"
alias apip3="/c/Develop/Anaconda3/Scripts/pip.exe"
alias aei3="/c/Develop/Anaconda3/Scripts/easy_install.exe"
05-11 08:17