Re: docs.zope.org automation

Hanno Schlichting <[email protected]>
Newsgroups gmane.comp.web.zope.devel
Message-ID <[email protected]>
On Tue, Aug 3, 2010 at 11:05 PM, Jens Vagelpohl <[email protected]> wrote:
> I understand that. But it must be possible to do that programatically in
> my code. I mean, "setup.py --long-description" obviously executes Python
> code, which I may be able to execute myself in my current interpreter
> session by importing and executing stuff from setuptools. Having to
> invoke another Python interpreter in a subshell because that's too
> complicated to do any other way is awful.

Maybe this gets you a bit further:

import os
from setuptools.sandbox import run_setup

package = os.path.join(os.curdir, 'zope.component')
os.chdir(package)
run_setup('setup.py', ['--long-description'])
os.chdir(os.pardir)


The run_setup call seems to dump the output to sys.stdout which might
be a bit painful to grab.

Hanno
_______________________________________________
Zope-Dev maillist  -  [email protected]
https://mail.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 https://mail.zope.org/mailman/listinfo/zope-announce
 https://mail.zope.org/mailman/listinfo/zope )
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.