I'm doing something wrong, and it's probably very obvious... from distutils.core import setup from distutils.core import Command class FooBar(Command): description = "foo. no! Bar!" user_options = [] def initialize_options(self): pass def finalize_options(self): pass def run(self): print "am I here?" self.announce("Run, I say!") setup( cmdclass = { "foobar" : FooBar } ) Running "python setup.py foobar" prints the "am I here?" line, but not the "Run, I say!" line. This is true even with the -v flag. *Should* this work? Kevin
At 03:09 PM 8/31/2005 -0400, Kevin Dangoor wrote:
I'm doing something wrong, and it's probably very obvious...
from distutils.core import setup
from distutils.core import Command
class FooBar(Command): description = "foo. no! Bar!" user_options = [] def initialize_options(self): pass
def finalize_options(self): pass
def run(self): print "am I here?" self.announce("Run, I say!")
setup( cmdclass = { "foobar" : FooBar } )
Running "python setup.py foobar" prints the "am I here?" line, but not the "Run, I say!" line. This is true even with the -v flag.
*Should* this work?
Dunno. But you should probably be using distutils.log.info() (or debug/warn/etc.) instead anyway.
On 8/31/05, Phillip J. Eby <pje@telecommunity.com> wrote:
Dunno. But you should probably be using distutils.log.info() (or debug/warn/etc.) instead anyway.
The funny thing is that I started using self.announce when I saw it in setuptools/command/test.py :) distutils.log.info works fine. Thanks! Kevin
participants (2)
-
Kevin Dangoor -
Phillip J. Eby