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 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 def _ParseDepsFile(filename): | 80 def _ParseDepsFile(filename): |
81 with open(filename, 'rb') as f: | 81 with open(filename, 'rb') as f: |
82 deps_content = f.read() | 82 deps_content = f.read() |
83 return _ParseDepsDict(deps_content) | 83 return _ParseDepsDict(deps_content) |
84 | 84 |
85 | 85 |
86 def _ParseDepsDict(deps_content): | 86 def _ParseDepsDict(deps_content): |
87 local_scope = {} | 87 local_scope = {} |
88 var = GClientKeywords.VarImpl({}, local_scope) | 88 var = GClientKeywords.VarImpl({}, local_scope) |
89 global_scope = { | 89 global_scope = { |
90 'From': GClientKeywords.FromImpl, | |
91 'Var': var.Lookup, | 90 'Var': var.Lookup, |
92 'deps_os': {}, | 91 'deps_os': {}, |
93 } | 92 } |
94 exec(deps_content, global_scope, local_scope) | 93 exec(deps_content, global_scope, local_scope) |
95 return local_scope | 94 return local_scope |
96 | 95 |
97 | 96 |
98 def _GenerateCLDescriptionCommand(swiftshader_current, swiftshader_new, bugs, | 97 def _GenerateCLDescriptionCommand(swiftshader_current, swiftshader_new, bugs, |
99 tbr): | 98 tbr): |
100 def GetChangeString(current_hash, new_hash): | 99 def GetChangeString(current_hash, new_hash): |
(...skipping 311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
412 logging.basicConfig(level=logging.ERROR) | 411 logging.basicConfig(level=logging.ERROR) |
413 | 412 |
414 autoroller = AutoRoller(SRC_DIR) | 413 autoroller = AutoRoller(SRC_DIR) |
415 if args.abort: | 414 if args.abort: |
416 return autoroller.Abort() | 415 return autoroller.Abort() |
417 else: | 416 else: |
418 return autoroller.PrepareRoll(args.ignore_checks, args.tbr, args.commit) | 417 return autoroller.PrepareRoll(args.ignore_checks, args.tbr, args.commit) |
419 | 418 |
420 if __name__ == '__main__': | 419 if __name__ == '__main__': |
421 sys.exit(main()) | 420 sys.exit(main()) |
OLD | NEW |