Bigger projects, including files?

globalrev skanemupp at
Sat Apr 19 20:08:09 EDT 2008

On 20 Apr, 02:04, "Martin P. Hellwig" <x... at> wrote:
> globalrev wrote:
> > if i have a larger project and want to divide my program into several
> > files, how do i include these files in the mainprogram?
> > using import someprojectfile doesnt work because import is for site-
> > packages right and i dont want to put all my files
> > in that folder.
> > so how do i do it?
> You can always add the path where the other files are to sys.path
> I've posted a while ago something that sort of does that for
> inter-package reference if the root is not in the sys.path
> hth
> --
> mph

thanks. i saw now myself that import works if it is in the same folder
as well.

More information about the Python-list mailing list