Re: import woe

2006-05-19 Thread Serge Orlov
[EMAIL PROTECTED] wrote: hello, i have a problem. i would like to import python files above and below my current directory. i'm working on /home/foo/bar/jar.py i would like to import /home/foo/car.py and /home/foo/bar/far.py how can i do this? $ cat ~/.bashrc

Re: import woe

2006-05-19 Thread vaibhav
Hi bob, 1. decide the directory which will be your root folder containing foo [/home/ROOT/foo/] 2. work out your directory structure relative to this root folder here it is -ROOT-foo-car.py -bar-far.py -bar-jar.py 3. add

Re: import woe

2006-05-19 Thread Terry Hancock
vaibhav wrote: 4. add the root folder to your sys.path so your jar.py file should have the following entries from sys import path path.append('../../../ROOT') note: i prefer relative paths Interesting that that works. I guess you could create a limited form of Zope acquisition type

import woe

2006-05-18 Thread gsocks
hello, i have a problem. i would like to import python files above and below my current directory. i'm working on /home/foo/bar/jar.py i would like to import /home/foo/car.py and /home/foo/bar/far.py how can i do this? thank you, bob ps: i want to scale, so i do not

Re: import woe

2006-05-18 Thread Gary Herron
[EMAIL PROTECTED] wrote: hello, i have a problem. i would like to import python files above and below my current directory. i'm working on /home/foo/bar/jar.py i would like to import /home/foo/car.py and /home/foo/bar/far.py how can i do this? thank you, bob ps: i