| OLD | NEW |
| 1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
| 2 # Copyright 2014 The Chromium Authors. All rights reserved. | 2 # Copyright 2014 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 # TODO(hinoka): Use logging. | 6 # TODO(hinoka): Use logging. |
| 7 | 7 |
| 8 import cStringIO | 8 import cStringIO |
| 9 import codecs | 9 import codecs |
| 10 import collections | 10 import collections |
| (...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 644 print 'Dropping %s:%s from custom deps' % (deps_name, deps_value) | 644 print 'Dropping %s:%s from custom deps' % (deps_name, deps_value) |
| 645 else: | 645 else: |
| 646 new_custom_deps[deps_name] = deps_value | 646 new_custom_deps[deps_name] = deps_value |
| 647 solution['custom_deps'] = new_custom_deps | 647 solution['custom_deps'] = new_custom_deps |
| 648 | 648 |
| 649 if first_solution: | 649 if first_solution: |
| 650 root = parsed_path | 650 root = parsed_path |
| 651 first_solution = False | 651 first_solution = False |
| 652 | 652 |
| 653 solution['managed'] = False | 653 solution['managed'] = False |
| 654 # We don't want gclient to be using a safesync URL. Instead it should | |
| 655 # using the lkgr/lkcr branch/tags. | |
| 656 if 'safesync_url' in solution: | |
| 657 print 'Removing safesync url %s from %s' % (solution['safesync_url'], | |
| 658 parsed_path) | |
| 659 del solution['safesync_url'] | |
| 660 return solutions, root, buildspec | 654 return solutions, root, buildspec |
| 661 | 655 |
| 662 | 656 |
| 663 def remove(target): | 657 def remove(target): |
| 664 """Remove a target by moving it into build.dead.""" | 658 """Remove a target by moving it into build.dead.""" |
| 665 dead_folder = path.join(BUILDER_DIR, 'build.dead') | 659 dead_folder = path.join(BUILDER_DIR, 'build.dead') |
| 666 if not path.exists(dead_folder): | 660 if not path.exists(dead_folder): |
| 667 os.makedirs(dead_folder) | 661 os.makedirs(dead_folder) |
| 668 os.rename(target, path.join(dead_folder, uuid.uuid4().hex)) | 662 os.rename(target, path.join(dead_folder, uuid.uuid4().hex)) |
| 669 | 663 |
| (...skipping 1102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1772 except Exception: | 1766 except Exception: |
| 1773 # Unexpected failure. | 1767 # Unexpected failure. |
| 1774 emit_flag(options.flag_file) | 1768 emit_flag(options.flag_file) |
| 1775 raise | 1769 raise |
| 1776 else: | 1770 else: |
| 1777 emit_flag(options.flag_file) | 1771 emit_flag(options.flag_file) |
| 1778 | 1772 |
| 1779 | 1773 |
| 1780 if __name__ == '__main__': | 1774 if __name__ == '__main__': |
| 1781 sys.exit(main()) | 1775 sys.exit(main()) |
| OLD | NEW |