summaryrefslogtreecommitdiffstats
path: root/update.py
diff options
context:
space:
mode:
authorZhongyue Luo <zhongyue.nah@intel.com>2013-05-14 17:52:43 +0800
committerZhongyue Luo <zhongyue.nah@intel.com>2013-05-14 20:49:57 +0800
commit0ccb7a836bd47c5bc7f77ab235f7ba583ee7ae14 (patch)
treea48e162b5bb97f601090345b142ddc8f0812ec8d /update.py
parent3e0114f570d97c47b1b8eefce0bcd27146098b8d (diff)
downloadoslo-0ccb7a836bd47c5bc7f77ab235f7ba583ee7ae14.tar.gz
oslo-0ccb7a836bd47c5bc7f77ab235f7ba583ee7ae14.tar.xz
oslo-0ccb7a836bd47c5bc7f77ab235f7ba583ee7ae14.zip
Adds --nodeps option to update.py
Discards dependencies of configured modules when set. Change-Id: I4210c9b2d96d4c0750175823b47e39b4097be6ac
Diffstat (limited to 'update.py')
-rw-r--r--update.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/update.py b/update.py
index 36ee3f2..2edc8ef 100644
--- a/update.py
+++ b/update.py
@@ -85,6 +85,9 @@ opts = [
default=None,
help='A config file or destination project directory',
positional=True),
+ cfg.BoolOpt('nodeps',
+ default=False,
+ help='Discard dependencies of configured modules'),
]
@@ -260,7 +263,9 @@ def _dfs_dependency_tree(dep_tree, mod_name, mod_list=[]):
return mod_list
-def _complete_module_list(mod_list):
+def _complete_module_list(mod_list, nodeps):
+ if nodeps:
+ return mod_list
addons = []
dep_tree = _build_dependency_tree()
for mod in mod_list:
@@ -292,7 +297,7 @@ def main(argv):
_create_module_init(conf.base, dest_dir)
_create_module_init(conf.base, dest_dir, 'common')
- for mod in _complete_module_list(conf.module + conf.modules):
+ for mod in _complete_module_list(conf.module + conf.modules, conf.nodeps):
_copy_module(mod, conf.base, dest_dir)