官术网_书友最值得收藏!

Prerequisites and tools

First, let's make sure our environment is properly configured. For this course, I assume you are using a Debian-like Linux distribution, such as Mint (http://www.linuxmint.com/) or Ubuntu (http://ubuntu.com/). All the instructions will be geared towards these systems.

Let's begin by installing the required Debian packages with apt-get as follows:

sudo apt-get install python-dev python-pip

This will install the Python development tools and libraries required for compiling Python packages, and pip: a neat tool you can use to install Python packages from the command line. On with it! Let's install our virtual environment managing tool:

sudo pip install virtualenvwrapper
echo "source /usr/local/bin/virtualenvwrapper.sh" >> ~/.bashrc

To explain what we just did: sudo tells our OS that we want administrative privileges to run the next command, and pip is the default Python package management tool and helps us install the virtualenvwrapper package. The second command statement adds a command to load the virtualenvwrapper.sh script together with the console, so that commands work inside your shell (we'll be using it, by the way).

主站蜘蛛池模板: 北海市| 石泉县| 孝义市| 鲁山县| 余姚市| 神木县| 利川市| 沙雅县| 双牌县| 普兰店市| 张家港市| 江城| 洛阳市| 灵武市| 鹰潭市| 南江县| 满城县| 垫江县| 广灵县| 武城县| 论坛| 广德县| 台中县| 固始县| 普格县| 礼泉县| 运城市| 峨边| 石柱| 木兰县| 枣庄市| 封丘县| 清丰县| 呼伦贝尔市| 乐至县| 南昌县| 连城县| 红原县| 庆安县| 赣榆县| 正镶白旗|