OLD | NEW |
| (Empty) |
1 #!/usr/bin/env python | |
2 # | |
3 # Copyright (c) 2014 The Chromium Authors. All rights reserved. | |
4 # Use of this source code is governed by a BSD-style license that can be | |
5 # found in the LICENSE file. | |
6 | |
7 """Writes a revision number into src/chrome/tools/test/reference_build/REVISON | |
8 Must be run from the root of a Dartium or multivm checkout. | |
9 | |
10 Usage: | |
11 $ ./src/dart/tools/bots/set_reference_build_revision.py <revision> | |
12 """ | |
13 | |
14 import os | |
15 import sys | |
16 | |
17 def main(argv): | |
18 revision = argv[1] | |
19 output = os.path.join('src', 'chrome', 'tools', | |
20 'test', 'reference_build', | |
21 'REQUESTED_REVISION') | |
22 dirname = os.path.dirname(output) | |
23 if dirname and not os.path.exists(dirname): | |
24 os.makedirs(dirname) | |
25 with file(output, 'w') as f: | |
26 f.write(revision) | |
27 | |
28 if __name__ == '__main__': | |
29 sys.exit(main(sys.argv)) | |
OLD | NEW |