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 import os | 6 import os |
7 import sys | 7 import sys |
8 from utils import commit | 8 from utils import commit |
9 from utils import mojo_root_dir | 9 from utils import mojo_root_dir |
10 from utils import system | 10 from utils import system |
11 | 11 |
12 dirs_to_clone = [ | 12 dirs_to_clone = [ |
13 "mojo/edk", | 13 "mojo/edk", |
14 "mojo/public", | 14 "mojo/public", |
15 "mojo/services/public", | 15 "mojo/services/public", |
| 16 "mojo/services/surfaces/public", |
16 "mojo/services/view_manager/public", | 17 "mojo/services/view_manager/public", |
17 "mojo/services/window_manager/public", | 18 "mojo/services/window_manager/public", |
18 ] | 19 ] |
19 | 20 |
20 def rev(source_dir, chromium_dir): | 21 def rev(source_dir, chromium_dir): |
21 src_commit = system(["git", "show-ref", "HEAD", "-s"], cwd=source_dir).strip() | 22 src_commit = system(["git", "show-ref", "HEAD", "-s"], cwd=source_dir).strip() |
22 | 23 |
23 for d in dirs_to_clone: | 24 for d in dirs_to_clone: |
24 print "removing directory %s" % d | 25 print "removing directory %s" % d |
25 system(["git", "rm", "-r", d], cwd=chromium_dir) | 26 system(["git", "rm", "-r", d], cwd=chromium_dir) |
(...skipping 13 matching lines...) Expand all Loading... |
39 with open("mojo/public/VERSION", "w") as version_file: | 40 with open("mojo/public/VERSION", "w") as version_file: |
40 version_file.write(src_commit) | 41 version_file.write(src_commit) |
41 system(["git", "add", "mojo/public/VERSION"], cwd=chromium_dir) | 42 system(["git", "add", "mojo/public/VERSION"], cwd=chromium_dir) |
42 commit("Update mojo sdk to rev " + src_commit, cwd=chromium_dir) | 43 commit("Update mojo sdk to rev " + src_commit, cwd=chromium_dir) |
43 | 44 |
44 if len(sys.argv) != 2: | 45 if len(sys.argv) != 2: |
45 print "usage: rev_sdk.py <chromium source dir>" | 46 print "usage: rev_sdk.py <chromium source dir>" |
46 sys.exit(1) | 47 sys.exit(1) |
47 | 48 |
48 rev(mojo_root_dir, sys.argv[1]) | 49 rev(mojo_root_dir, sys.argv[1]) |
OLD | NEW |