I\'ve got a project where I would like to use some python classes located in other directories.
Example structure:
/dir
+../subdirA
+../subdirB
+../my
On dir structure as following:
/dir
+../subdirA
+../subdirB
+../mydir
combining with linux command ln
, we can make things a lot simpler:
1. cd dir/mydir
2. ln -s ../subdirA ./
3. ln -s ../subdirB ./
And, now if you want to import some_stuff
from file: dir/subdirA/fileA.py
into your file: dir/mydir/myfile.py
, simply import like this:
from subdirA.fileA import some_stuff
And, the same applies to 'dir/subdirB'
What's More, this works for setup.py
process, :)