Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Python > where is Python Tools/scripts directory?

Reply
Thread Tools

where is Python Tools/scripts directory?

 
 
Michele Simionato
Guest
Posts: n/a
 
      05-15-2004
Is there a simple way to get the path to the Python Tools/scripts directory?

Currently I have defined by hand an environment variable such as

PYTHONSCRIPTS=/home/myhome/packages/Python-2.3.3/Tools/scripts

so I can alias the more useful scripts in my .bashrc (for instance
alias dutree=$PYTHONSCRIPTS/dutree.py), but this approach is PITA,
I have to change the variable each time I change machine and at each
new Python version. Is there a better way?

TIA,

Michele Simionato
 
Reply With Quote
 
 
 
 
Skip Montanaro
Guest
Posts: n/a
 
      05-15-2004

Michele> Is there a simple way to get the path to the Python
Michele> Tools/scripts directory? Currently I have defined by hand an
Michele> environment variable such as

Michele> PYTHONSCRIPTS=/home/myhome/packages/Python-2.3.3/Tools/scripts

Michele> so I can alias the more useful scripts in my .bashrc (for
Michele> instance alias dutree=$PYTHONSCRIPTS/dutree.py), but this
Michele> approach is PITA, I have to change the variable each time I
Michele> change machine and at each new Python version. Is there a
Michele> better way?

I'm not aware of a better way short of identifying those scripts of interest
and modifying setup.py to install them in $PREFIX/bin. In setup.py search
for "Tools/scripts" and modify the list. Feel free to submit a patch to SF
if you think those scripts would be of broader interest and ought to be
installed by default.

Skip

 
Reply With Quote
 
 
 
 
Michele Simionato
Guest
Posts: n/a
 
      05-18-2004
Skip Montanaro <(E-Mail Removed)> wrote in message news:<(E-Mail Removed)>...
> Michele> Is there a simple way to get the path to the Python
> Michele> Tools/scripts directory?
> I'm not aware of a better way short of identifying those scripts of interest
> and modifying setup.py to install them in $PREFIX/bin. In setup.py search
> for "Tools/scripts" and modify the list. Feel free to submit a patch to SF
> if you think those scripts would be of broader interest and ought to be
> installed by default.
>


I just discovered that in my installation at work (which is a Debian
distribution not managed by me) there is a copy of Tools/scripts in

/usr/share/doc/python2.3/examples/Tools/scripts

May I assume that this location is typical of Linux installations?


Michele
 
Reply With Quote
 
Skip Montanaro
Guest
Posts: n/a
 
      05-18-2004

Michele> I just discovered that in my installation at work (which is a
Michele> Debian distribution not managed by me) there is a copy of
Michele> Tools/scripts in

Michele> /usr/share/doc/python2.3/examples/Tools/scripts

Michele> May I assume that this location is typical of Linux
Michele> installations?

I think that would be an invalid assumption.

Skip

 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: [Python-Dev] [python-committers] [RELEASED] Python 3.2 rc 1 R. David Murray Python 0 01-17-2011 02:23 PM
Re: [Python-Dev] [python-committers] [RELEASED] Python 3.2 rc 1 Senthil Kumaran Python 0 01-17-2011 10:31 AM
Re: [Python-Dev] [Python-3000] RELEASED Python 2.6a1 and 3.0a3 Martin v. L÷wis Python 0 03-01-2008 10:51 PM
Re: [Python-Dev] [Python-3000] RELEASED Python 2.6a1 and 3.0a3 Paul Moore Python 0 03-01-2008 10:39 PM
Searching comp.lang.python/python-list@python.org (was: UTF-8) skip@pobox.com Python 0 03-10-2007 02:50 PM



Advertisments