How to change the path for python binary?

Alex Martelli aleax at mac.com
Fri Aug 11 01:45:05 EDT 2006


Nico Grubert <nicogrubert at gmail.com> wrote:

> Hi there,
> 
> I have installed Python 2.3.5 on Suse Linux 10.
> If I enter "python" in the shell, the Python 2.3.5 interpreter is called.
> 
> After I installed Python 2.4.3. the Python 2.4.3 interpreter is called
> which is the default behaviour I guess.
> 
> "which python" brings me "/usr/local/bin/python" which calls the Python
> 2.4.3 interpreter.
> 
> My question now is:
> What do I have to do in order to get the Python 2.3.5 interpreter each
> time I enter "python" in the shell?

One sufficient idea might be to put in your .bashrc file (or the like) a
statement such as

alias python=python2.3


Alex



More information about the Python-list mailing list