| OLD | NEW |
| 1 # Copyright 2016 The LUCI Authors. All rights reserved. | 1 # Copyright 2016 The LUCI Authors. All rights reserved. |
| 2 # Use of this source code is governed under the Apache License, Version 2.0 | 2 # Use of this source code is governed under the Apache License, Version 2.0 |
| 3 # that can be found in the LICENSE file. | 3 # that can be found in the LICENSE file. |
| 4 | 4 |
| 5 from __future__ import print_function | 5 from __future__ import print_function |
| 6 | 6 |
| 7 import argparse | |
| 8 import sys | 7 import sys |
| 9 | 8 |
| 10 from . import loader | 9 from . import loader |
| 11 | 10 |
| 11 from . import env |
| 12 |
| 13 import argparse # this is vendored |
| 14 |
| 12 | 15 |
| 13 _GRAPH_HEADER = """strict digraph { | 16 _GRAPH_HEADER = """strict digraph { |
| 14 concentrate = true; | 17 concentrate = true; |
| 15 ranksep = 2; | 18 ranksep = 2; |
| 16 nodesep = 0.25; | 19 nodesep = 0.25; |
| 17 """ | 20 """ |
| 18 | 21 |
| 19 _GRAPH_FOOTER = """} | 22 _GRAPH_FOOTER = """} |
| 20 """ | 23 """ |
| 21 | 24 |
| (...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 136 print(' subgraph "cluster_%s" { label="%s"; %s; }' % ( | 139 print(' subgraph "cluster_%s" { label="%s"; %s; }' % ( |
| 137 package, package, '; '.join(modules)), file=args.output) | 140 package, package, '; '.join(modules)), file=args.output) |
| 138 | 141 |
| 139 if args.recipe_filter and recipe_to_package: | 142 if args.recipe_filter and recipe_to_package: |
| 140 recipe_names = [ | 143 recipe_names = [ |
| 141 '"recipe %s"' % name for name in recipe_to_package.keys()] | 144 '"recipe %s"' % name for name in recipe_to_package.keys()] |
| 142 print(' subgraph "cluster_recipes" { label="recipes"; %s; }' % ( | 145 print(' subgraph "cluster_recipes" { label="recipes"; %s; }' % ( |
| 143 '; '.join(recipe_names)), file=args.output) | 146 '; '.join(recipe_names)), file=args.output) |
| 144 | 147 |
| 145 print(_GRAPH_FOOTER, file=args.output) | 148 print(_GRAPH_FOOTER, file=args.output) |
| OLD | NEW |