Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(360)

Side by Side Diff: tools/patch_sdk.py

Issue 2464833002: Fix Debian builder. (Closed)
Patch Set: Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « runtime/vm/vm.gypi ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file 2 # Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file
3 # for details. All rights reserved. Use of this source code is governed by a 3 # for details. All rights reserved. Use of this source code is governed by a
4 # BSD-style license that can be found in the LICENSE file. 4 # BSD-style license that can be found in the LICENSE file.
5 5
6 import argparse
6 import os 7 import os
7 import subprocess 8 import subprocess
8 import sys 9 import sys
9 import utils 10 import utils
10 11
12 usage = """patch_sdk.py [options]"""
13
14 def BuildArguments():
15 result = argparse.ArgumentParser(usage=usage)
16 result.add_argument("--dart-executable", help="dart executable", default=None)
17 return result
18
11 def main(): 19 def main():
12 dart = os.path.join(utils.CheckedInSdkPath(), 'bin', 'dart') 20 # Parse the options.
21 parser = BuildArguments()
22 (options, args) = parser.parse_known_args()
23 if options.dart_executable is not None:
24 options.dart_executable = os.path.abspath(options.dart_executable)
25 else:
26 options.dart_executable = os.path.join(utils.CheckedInSdkPath(), 'bin', 'dar t')
13 dart_file = os.path.join(os.path.dirname(__file__), 'patch_sdk.dart') 27 dart_file = os.path.join(os.path.dirname(__file__), 'patch_sdk.dart')
14 subprocess.check_call([dart, dart_file] + sys.argv[1:]); 28 subprocess.check_call([options.dart_executable, dart_file] + args);
15 29
16 if __name__ == '__main__': 30 if __name__ == '__main__':
17 main() 31 main()
OLDNEW
« no previous file with comments | « runtime/vm/vm.gypi ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698