OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright 2015 The Chromium Authors. All rights reserved. | 2 # Copyright 2015 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 import argparse | 6 import argparse |
7 import collections | 7 import collections |
8 import logging | 8 import logging |
9 import os | 9 import os |
10 import re | 10 import re |
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
74 def _ParseDepsFile(filename): | 74 def _ParseDepsFile(filename): |
75 with open(filename, 'rb') as f: | 75 with open(filename, 'rb') as f: |
76 deps_content = f.read() | 76 deps_content = f.read() |
77 return _ParseDepsDict(deps_content) | 77 return _ParseDepsDict(deps_content) |
78 | 78 |
79 | 79 |
80 def _ParseDepsDict(deps_content): | 80 def _ParseDepsDict(deps_content): |
81 local_scope = {} | 81 local_scope = {} |
82 var = GClientKeywords.VarImpl({}, local_scope) | 82 var = GClientKeywords.VarImpl({}, local_scope) |
83 global_scope = { | 83 global_scope = { |
84 'File': GClientKeywords.FileImpl, | |
85 'From': GClientKeywords.FromImpl, | 84 'From': GClientKeywords.FromImpl, |
86 'Var': var.Lookup, | 85 'Var': var.Lookup, |
87 'deps_os': {}, | 86 'deps_os': {}, |
88 } | 87 } |
89 exec(deps_content, global_scope, local_scope) | 88 exec(deps_content, global_scope, local_scope) |
90 return local_scope | 89 return local_scope |
91 | 90 |
92 | 91 |
93 def _GenerateCLDescriptionCommand(webgl_current, webgl_new, bugs): | 92 def _GenerateCLDescriptionCommand(webgl_current, webgl_new, bugs): |
94 def GetChangeString(current_hash, new_hash): | 93 def GetChangeString(current_hash, new_hash): |
(...skipping 293 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
388 logging.basicConfig(level=logging.ERROR) | 387 logging.basicConfig(level=logging.ERROR) |
389 | 388 |
390 autoroller = AutoRoller(SRC_DIR) | 389 autoroller = AutoRoller(SRC_DIR) |
391 if args.abort: | 390 if args.abort: |
392 return autoroller.Abort() | 391 return autoroller.Abort() |
393 else: | 392 else: |
394 return autoroller.PrepareRoll(args.ignore_checks, args.run_tryjobs) | 393 return autoroller.PrepareRoll(args.ignore_checks, args.run_tryjobs) |
395 | 394 |
396 if __name__ == '__main__': | 395 if __name__ == '__main__': |
397 sys.exit(main()) | 396 sys.exit(main()) |
OLD | NEW |