Installing Python setup tools on Unix to run Tweepy Twitter client for Python
Question: I am trying to run Tweepy client for Twitter on my Unix account. whenever i
try to run setup for Tweepy using the command:

    
    
    python setup.py
    

I get this error:

    
    
    Traceback (most recent call last):
    File "setup.py", line 3, in ?
    from setuptools import setup, find_packages
    ImportError: No module named setuptools
    

Now i searched on some forums and found i need to add setup tools file. The
file i found

    
    
    setuptools-0.6c11-py2.7.egg
    

I FTP - ed this file to my unix directory where i have Tweepy client directory
and my program which is using Tweepy.

Now, whenever i try to install setup tools using the command

    
    
    python setuptools-0.6c11-py2.7.egg
    

I get the error :

    
    
    python setuptools-0.6c11-py2.7.egg
      File "setuptools-0.6c11-py2.7.egg", line 2
        if [ `basename $0` = "setuptools-0.6c11-py2.7.egg" ]
                       ^
    SyntaxError: invalid syntax
    

Any clues/suggestions what i must be doing wrong here ?


Answer: Don't use setuptools, use
[distribute](http://pypi.python.org/pypi/distribute/). Setuptools is old and
deprecated. Until python 3.4 with packaging/distutils2 is around use
distribute, which is a fork of old setuptools/distutils.

Simply download the distribute source tarball, unpack and run `python setup.py
install`. Alternatively, you can download [distribute-
setup.py](http://pypi.python.org/pypi/distribute/#distribute-setup-py) and
just run it.

