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 '''Tool to roll Mojo into Chromium. See: | 6 '''Tool to roll Mojo into Chromium. See: |
7 https://github.com/domokit/mojo/wiki/Rolling-code-between-chromium-and-mojo#mojo
---chromium-updates-sdk--edk | 7 https://github.com/domokit/mojo/wiki/Rolling-code-between-chromium-and-mojo#mojo
---chromium-updates-sdk--edk |
8 ''' | 8 ''' |
9 | 9 |
10 import os | 10 import os |
(...skipping 15 matching lines...) Expand all Loading... |
26 'mojo/public/interfaces/network', | 26 'mojo/public/interfaces/network', |
27 'mojo/public/java/application', | 27 'mojo/public/java/application', |
28 ] | 28 ] |
29 | 29 |
30 # Individual files to preserve within the target repository during roll. These | 30 # Individual files to preserve within the target repository during roll. These |
31 # are relative to |sdk_prefix_in_chromium| but are not maintained in the mojo | 31 # are relative to |sdk_prefix_in_chromium| but are not maintained in the mojo |
32 # repository. | 32 # repository. |
33 preserved_chromium_files = [ | 33 preserved_chromium_files = [ |
34 'mojo/edk/DEPS', | 34 'mojo/edk/DEPS', |
35 'mojo/public/DEPS', | 35 'mojo/public/DEPS', |
36 'mojo/public/c/gpu/DEPS', | |
37 'mojo/public/platform/nacl/DEPS', | 36 'mojo/public/platform/nacl/DEPS', |
38 'nacl_bindings/DEPS', | 37 'nacl_bindings/DEPS', |
39 ] | 38 ] |
40 | 39 |
41 # A dictionary mapping dirs to clone to their destination locations in Chromium. | 40 # A dictionary mapping dirs to clone to their destination locations in Chromium. |
42 dirs_to_clone = {} | 41 dirs_to_clone = {} |
43 | 42 |
44 for sdk_dir in sdk_dirs_to_clone: | 43 for sdk_dir in sdk_dirs_to_clone: |
45 sdk_dir_in_chromium = os.path.join(sdk_prefix_in_chromium, sdk_dir) | 44 sdk_dir_in_chromium = os.path.join(sdk_prefix_in_chromium, sdk_dir) |
46 dirs_to_clone[sdk_dir] = sdk_dir_in_chromium | 45 dirs_to_clone[sdk_dir] = sdk_dir_in_chromium |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 | 91 |
93 commit('Update mojo sdk to rev ' + src_commit, cwd=chromium_dir) | 92 commit('Update mojo sdk to rev ' + src_commit, cwd=chromium_dir) |
94 | 93 |
95 if len(sys.argv) < 2: | 94 if len(sys.argv) < 2: |
96 print 'usage: rev_sdk.py <mojo source dir> [<mojo revision>]' | 95 print 'usage: rev_sdk.py <mojo source dir> [<mojo revision>]' |
97 sys.exit(1) | 96 sys.exit(1) |
98 | 97 |
99 # Allow override of the roll revision. | 98 # Allow override of the roll revision. |
100 revision = sys.argv[2] if len(sys.argv) == 3 else 'origin/HEAD' | 99 revision = sys.argv[2] if len(sys.argv) == 3 else 'origin/HEAD' |
101 rev(sys.argv[1], chromium_root_dir, revision) | 100 rev(sys.argv[1], chromium_root_dir, revision) |
OLD | NEW |