diff options
author | Narayan Desai <desai@mcs.anl.gov> | 2006-03-17 17:25:46 +0000 |
---|---|---|
committer | Narayan Desai <desai@mcs.anl.gov> | 2006-03-17 17:25:46 +0000 |
commit | 53bf23b62ae561f6525e4d4eb1396590125988b6 (patch) | |
tree | 32c043570a9b3815ce0dcf319f1288031b8c50ba /tools | |
parent | 372d4521c1f8e37ed691025e5632345fbfed4c3c (diff) | |
download | bcfg2-53bf23b62ae561f6525e4d4eb1396590125988b6.tar.gz bcfg2-53bf23b62ae561f6525e4d4eb1396590125988b6.tar.bz2 bcfg2-53bf23b62ae561f6525e4d4eb1396590125988b6.zip |
* Fix implicit groups for Cory
git-svn-id: https://svn.mcs.anl.gov/repos/bcfg/trunk/bcfg2@1805 ce84e21b-d406-0410-9b95-82705330c041
Diffstat (limited to 'tools')
-rwxr-xr-x | tools/groups-to-dot.py | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/tools/groups-to-dot.py b/tools/groups-to-dot.py index ee8e86348..86c47a398 100755 --- a/tools/groups-to-dot.py +++ b/tools/groups-to-dot.py @@ -42,13 +42,14 @@ if __name__ == '__main__': bundles.sort() for bundle in bundles: dotpipe.tochild.write('''\t"bundle-%s" [ label="%s", shape="septagon"];\n''' % (bundle, bundle)) - + gseen = [] for group in groups.findall('Group'): color = categories[group.get('category', 'default')] if group.get('profile', 'false') == 'true': style="filled, bold" else: style = "filled" + gseen.append(group.get('name')) dotpipe.tochild.write('\t"group-%s" [label="%s", style="%s", fillcolor=%s];\n' % (group.get('name'), group.get('name'), style, color)) if '-b' in sys.argv: @@ -58,6 +59,10 @@ if __name__ == '__main__': for group in groups.findall('Group'): for parent in group.findall('Group'): + if parent.get('name') not in gseen: + dotpipe.tochild.write('\t"group-%s" [label="%s", style="filled", fillcolor="grey83"];\n' % + (parent.get('name'), parent.get('name'))) + gseen.append(parent.get("name")) dotpipe.tochild.write('\t"group-%s" -> "group-%s" ;\n' % (group.get('name'), parent.get('name'))) dotpipe.tochild.write("\tsubgraph cluster_key {\n") |