how to find the directory where python is installed ?
Stef Mientki
stef.mientki at gmail.com
Thu Oct 2 15:46:27 EDT 2008
Timothy Grant wrote:
> On Thu, Oct 2, 2008 at 12:16 PM, Stef Mientki <stef.mientki at gmail.com> wrote:
>
>> hello,
>>
>> how can I determine the location of the Python installation under winXP /
>> Linux,
>> with a Python program ?
>>
>> thanks,
>> Stef Mientki
>>
>> --
>> http://mail.python.org/mailman/listinfo/python-list
>>
>>
>
> This what you're looking for?
>
> (tjg at bastard%) python
> Python 2.5.1 (r251:54863, Jan 17 2008, 19:35:16)
> [GCC 4.0.1 (Apple Inc. build 5465)] on darwin
> Type "help", "copyright", "credits" or "license" for more information.
>
>>>> import sys
>>>> sys.executable
>>>>
> '/System/Library/Frameworks/Python.framework/Versions/2.5/Resources/Python.app/Contents/MacOS/Python'
>
Yes that might be sufficient.
thanks,
Stef
More information about the Python-list
mailing list