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

Side by Side Diff: scripts/tools/run_recipe.py

Issue 17635005: Make blink_trybot recipe work on windows (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/tools/build
Patch Set: Address comments Created 7 years, 5 months 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 | Annotate | Revision Log
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python -u
2 # Copyright (c) 2013 The Chromium Authors. All rights reserved. 2 # Copyright (c) 2013 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 """This allows easy execution of a recipe (scripts/slave/recipes, etc.) 6 """This allows easy execution of a recipe (scripts/slave/recipes, etc.)
7 without buildbot. 7 without buildbot.
8 8
9 This is currently useful for testing recipes locally while developing them. 9 This is currently useful for testing recipes locally while developing them.
10 10
11 Example: 11 Example:
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 def main(argv): 86 def main(argv):
87 fp, bp = parse_args(argv) 87 fp, bp = parse_args(argv)
88 88
89 if not os.path.exists(SLAVE_DIR): 89 if not os.path.exists(SLAVE_DIR):
90 os.makedirs(SLAVE_DIR) 90 os.makedirs(SLAVE_DIR)
91 91
92 env = os.environ.copy() 92 env = os.environ.copy()
93 env['RUN_SLAVE_UPDATED_SCRIPTS'] = '1' 93 env['RUN_SLAVE_UPDATED_SCRIPTS'] = '1'
94 env['PYTHONUNBUFFERED'] = '1' 94 env['PYTHONUNBUFFERED'] = '1'
95 return subprocess.call( 95 return subprocess.call(
96 ['python', RUNIT, 'python', ANNOTATED_RUN, 96 ['python', '-u', RUNIT, 'python', '-u', ANNOTATED_RUN,
97 '--keep-stdin', # so that pdb works for local execution 97 '--keep-stdin', # so that pdb works for local execution
98 '--factory-properties', json.dumps(fp), 98 '--factory-properties', json.dumps(fp),
99 '--build-properties', json.dumps(bp)], 99 '--build-properties', json.dumps(bp)],
100 cwd=SLAVE_DIR, 100 cwd=SLAVE_DIR,
101 env=env) 101 env=env)
102 102
103 103
104 if __name__ == '__main__': 104 if __name__ == '__main__':
105 sys.exit(main(sys.argv)) 105 sys.exit(main(sys.argv))
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698