[Distutils] Splitting metadata from setup.py in distutils..

David Lyon david.lyon at preisshare.net
Mon Aug 17 17:23:43 CEST 2009

On Mon, 17 Aug 2009 16:09:31 +0100, Chris Withers <chris at simplistix.co.uk>
>> We must resist the option to nest (against unnecessary complexity). 
>> ConfigParser does lists easily so you can store a list of files 
>> extremely easily.
> Cool, what's the format for lists?

If there isn't a built in format for lists, you can simulate it
by numbering items. Eg:

file1 = abc.txt
file2 = def.txt

>> It also does free form text (descriptions).
> And for this?

>From my observations it seems to tabulate the first column. Eg:

description = This package converts popular tv soap operas
        into something that is readily viewable on your
        python powered mobile phone.

>> For me, that only leaves the choice of a filename.. 
>>  - setup.info
>>  - setup.conf
>>  - others..?
> ...is entirely up to the package developer. We can suggest whatever, but 
> since it'll be called from setup.py, we can't do anything other than 
> suggest a sensible default that will work with the tools that will 
> hopefully show up that only parse the static file...

My idea was to have the distutils "setup()" read the data from the 
config file. Defaulting to a particular file with a particular name.

Since we have a convention for setup.py, adding the convention for
a particular 'setup.info'/'setup.xml'/'package.setup' doesn't seem to
me to be a difficult ask. As long as it has 'setup' included somewhere
in the filename.

>> Having a setup.py and a setup.info to me seems simple and
>> straightforward. It's easier to understand than having all
>> the metadata 'hardcoded' in a program (as "cute" as that is).
> For some packages (see lxml for example) it's not cute but a necessity 
> to figure out how to build their extensions properly...

ok - I'll check it out.


More information about the Distutils-SIG mailing list