class InstallCommand(Command):
    description = 'Installs the foo.'
user_options = [('foo=', None, 'Specify the foo to bar.')]

def initialize_options(self):
    self.foo = None

def finalize_options(self):
    assert self.foo in (None, 'myFoo', 'myFoo2'), 'Invalid foo!'

def run(self):
    pass
distutils: Как передать пользовательский параметр в setup.py?