[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Ideal directory structure?



On Sat, 2010-30-01 at 21:03 +0530, Umang wrote:
> However, my 
> foolib will have 99.9% of my code. foolib _is_ my program, it's not a 

Why not just have foo.py then ?

There *are* python programs written this way.  I think you can still use
them as libraries if you use the __main__ convention at the end.  The
classes can always be separated at a later date.  The 'import' mechanism
is one of the really nice things about python (vs perl).

> library. foo simply starts the whole process - parses command line 
> options, initiates classes and calls the appropriate methods. 
-- 
--gh



Reply to: