Babun is “A Windows shell you will love!”
It's a turn-key CygWin distribution for developers and is very easy to install and maintain. For a Python developer, Babun allows working in an almost-POSIX environment – with some limitation, of course. This causes less friction when handling FOSS projects that are often biased towards a standard Linux environment, e.g. by using shell scripts for boot-strapping and things like that.
-
Download the installer ZIP archive from the
Babun homepage <http://babun.github.io/>
_. -
Unzip it (e.g. using Windows Explorer).
-
Double-click the installer (
install.bat
), and wait… -
Catch up (
babun update
). -
Change the default shell from
zsh
tobash
if you're used to it (babun shell /bin/bash
). -
Edit
~/.bashrc
to activate loading of~/.bash_aliases
. -
Install additional Python essentials::
pact install python-setuptools python-ming pact install libxml2-devel libxslt-devel libyaml-devel curl -skS https://bootstrap.pypa.io/get-pip.py | python (optional) pip install virtualenv (optional) curl -skS https://raw.githubusercontent.com/mitsuhiko/pipsi/master/get-pipsi.py | python
My babun still use different pip from $PATH (I had installed anaconda, so it find a pip installed in anaconda)
But it use correct python from bubbn (can use whereis python
to check)
I use following command to check if pip is installed:
python -m ensurepip
, and the output show pip already install
Requirement already satisfied: setuptools in /usr/lib/python2.7/site-packages
Requirement already satisfied: pip in /usr/lib/python2.7/site-packages
Requirement already satisfied: appdirs>=1.4.0 in /usr/lib/python2.7/site-packages (from setuptools)
Requirement already satisfied: packaging>=16.8 in /usr/lib/python2.7/site-packages (from setuptools)
Requirement already satisfied: six>=1.6.0 in /usr/lib/python2.7/site-packages (from setuptools)
Requirement already satisfied: pyparsing in /usr/lib/python2.7/site-packages (from packaging>=16.8->setuptools)
It seems install but did not have executable pip
file
Currently, I find a workaround way use pip init.py file to run pip
# swtich path to where pip is installed
cd /usr/lib/python2.7/site-packages/pip/
# use python to run pip __init__.py (main), such as checking current install python module
python __init__.py list
# or search package
python __init__.py search pygments
# then install
python __init__.py install pygments
Could set alias, such as alias pip_babun='python /usr/lib/python2.7/site-packages/pip/__init__.py'
for convenience.
- Enjoy!