diff options
author | Mark McLoughlin <markmc@redhat.com> | 2013-03-12 17:21:50 +0000 |
---|---|---|
committer | Mark McLoughlin <markmc@redhat.com> | 2013-03-12 17:23:00 +0000 |
commit | a2223d49c8d5e27951b702a5b8a59a278f03fb74 (patch) | |
tree | 462303c4ee4a24e5edef8f3be8542705eac079eb /update.py | |
parent | 55b35226cf027100248ddcb11d8a7186c1635ddf (diff) | |
download | oslo-a2223d49c8d5e27951b702a5b8a59a278f03fb74.tar.gz oslo-a2223d49c8d5e27951b702a5b8a59a278f03fb74.tar.xz oslo-a2223d49c8d5e27951b702a5b8a59a278f03fb74.zip |
update.py: support one-module-per-line configuration
Fixes bug #1122701
Allow:
module=foo
module=bar
rather than
modules=foo,bar
to make reviewing changes easier.
Change-Id: Ic0a7fb28fd34f530c93806a5fb79ed3dc3bc494e
Diffstat (limited to 'update.py')
-rw-r--r-- | update.py | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -68,7 +68,11 @@ from oslo.config import cfg opts = [ cfg.ListOpt('modules', default=[], - help='The list of modules to copy from openstack-common'), + help='The list of modules to copy from oslo-incubator ' + '(deprecated in favor of --module)'), + cfg.MultiStrOpt('module', + default=[], + help='The list of modules to copy from oslo-incubator'), cfg.StrOpt('base', default=None, help='The base module to hold the copy of openstack.common'), @@ -229,7 +233,7 @@ def main(argv): print >> sys.stderr, "A valid destination dir is required" sys.exit(1) - if not conf.modules: + if not conf.module and not conf.modules: print >> sys.stderr, "A list of modules to copy is required" sys.exit(1) @@ -240,7 +244,7 @@ def main(argv): _create_module_init(conf.base, dest_dir) _create_module_init(conf.base, dest_dir, 'common') - for mod in conf.modules: + for mod in conf.module + conf.modules: _copy_module(mod, conf.base, dest_dir) |