Showing posts with label modules. Show all posts
Showing posts with label modules. Show all posts

Thursday, April 3, 2008

Where are the Python modules in this computer?

Start you python command prompt, and type:
>>import sys
>>sys.path
( it will print out a list of directories)

Another way is write a python script that prints the list out a little prettier:

#!/usr/bin/env python
import sys

for x in sys.path:
        print x
# add to the list of paths with this:
a="/Users/lance/bin/"
sys.path.append(a)