I wrote a small database access module that is reused in many programs.
My code is stored in a tree of one tree /projectsfor backup and version purposes, so the module should be placed in this directory tree, for example /projects/my_py_lib/dbconn.py.
I want to easily configure Python to automatically search for modules in a directory structure /projects/my_py_lib(of course, it __init__.pyshould be placed in any subdirectory).
What is the best way to do this on Ubuntu?
Thank,
Adam
source
share