[Distutils] Best practices on distributing documentation and examples with eggs?

Philipp von Weitershausen philipp at weitershausen.de
Tue Jul 31 08:48:35 CEST 2007


Phillip J. Eby wrote:
> At 02:55 PM 7/26/2007 -0400, Barry Warsaw wrote:
> 
>> On Jul 26, 2007, at 11:52 AM, Phillip J. Eby wrote:
>>
>>> There are a few different ways you could do this.  The easiest would
>>> be to put a docs subdirectory either inside one of your packages or
>>> inside your .egg-info directory, then use the pkg_resources resource
>>> or metadata APIs to list and extract them.  One advantage to using
>>> something like .egg-info/docs would be that this could perhaps be
>>> recognized by some sort of "standard" tools in the future.
>> I always thought .egg-info was just an artifact of the build.
> 
> No - it's also a place for metadata that doesn't live under a 
> specific package directory.
> 
>> Recommending that things get put there means it should get version
>> controlled.
> 
> Yep.

But isn't .egg-info completely recreatable through setup.py? Given that 
all it really does is present information from setup.py in a different 
manner, I've always been putting it on my svn:ignore list and only 
version-controlled the canonical source -- setup.py. That's becaue I can 
see and have seen the information get out of synch easily, e.g. if 
somebody changes setup.py but forgets to run setup.py egg_info.


-- 
http://worldcookery.com -- Professional Zope documentation and training


More information about the Distutils-SIG mailing list