.. _environment-setup: Environment Setup ***************** In order to write and run a Tigres program, the Tigres Python API needs to be installed. We recommend setting up a Tigres python environment with virtualenv. The following instructions assume that you have at least Python 2.7.x, setuptools_ and virtualenv_ installed on your system. If you don't have these installed, here are some pointers to get these installed: Install Setuptools ================== If you don't have setuptools installed, choose the instructions below for your machine architecture: * Unix_ * Mac-Os_ .. _virtualenv: https://pypi.python.org/pypi/virtualenv .. _setuptools: https://pypi.python.org/pypi/setuptools .. _Unix: https://pypi.python.org/pypi/setuptools#unix-wget .. _Mac-Os: https://pypi.python.org/pypi/setuptools#unix-including-mac-os-x-curl Install Virtualenv ================== Once you have setuptools installed, you can easily install any python module with the `easy_install` command. Now install virtualenv:: sudo easy_install virtualenv Install Tigres API ================== Installing Tigres involves creating a virtualenv environment for Tigres development and then installing Tigres. Setup Tigres VirtualEnv ----------------------- In order to create a virtualenv environment for Tigres, you need to set up a directory that contains all virtualenv environments, if you don't already have one:: $ export VIRTUALENV_HOME=$HOME/.virtualenv $ mkdir $VIRTUALENV_HOME $ virtualenv $VIRTUALENV_HOME/envtigres Download and install Tigres --------------------------- The last step is to activate the Tigres virtualenv environment you just created and install the Tigres API. `Download `_ the Tigres |release| source distribution from the `Tigres bitbucket repository `_. .. parsed-literal:: $ source $VIRTUALENV_HOME/envtigres/bin/activate (envtigres)$ cd (envtigres)$ pip install --no-index tigres-|release|.tar.gz