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

Side by Side Diff: client/example/payload/hello_world.py

Issue 1860863002: Update copyright notice from Swarming to LUCI; add AUTHORS and CONTRIBUTORS. (Closed) Base URL: git@github.com:luci/luci-py.git@master
Patch Set: . Created 4 years, 8 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
« no previous file with comments | « client/example/payload/hello_world.isolate ('k') | client/isolate.py » ('j') | 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 2012 The Swarming Authors. All rights reserved. 2 # Copyright 2012 The LUCI Authors. All rights reserved.
3 # Use of this source code is governed under the Apache License, Version 2.0 that 3 # Use of this source code is governed by the Apache v2.0 license that can be
4 # can be found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 """This script is meant to be run on a Swarming slave.""" 6 """This script is meant to be run on a Swarming slave."""
7 7
8 import os 8 import os
9 import sys 9 import sys
10 10
11 11
12 def main(): 12 def main():
13 print('Hello world: ' + sys.argv[1]) 13 print('Hello world: ' + sys.argv[1])
14 if len(sys.argv) == 3: 14 if len(sys.argv) == 3:
15 # Write a file in ${ISOLATED_OUTDIR}. 15 # Write a file in ${ISOLATED_OUTDIR}.
16 with open(os.path.join(sys.argv[2], 'happiness.txt'), 'wb') as f: 16 with open(os.path.join(sys.argv[2], 'happiness.txt'), 'wb') as f:
17 f.write( 17 f.write(
18 'is where you look %d/%d' % ( 18 'is where you look %d/%d' % (
19 int(os.environ['GTEST_SHARD_INDEX']), 19 int(os.environ['GTEST_SHARD_INDEX']),
20 int(os.environ['GTEST_TOTAL_SHARDS']))) 20 int(os.environ['GTEST_TOTAL_SHARDS'])))
21 return 0 21 return 0
22 22
23 23
24 if __name__ == '__main__': 24 if __name__ == '__main__':
25 sys.exit(main()) 25 sys.exit(main())
OLDNEW
« no previous file with comments | « client/example/payload/hello_world.isolate ('k') | client/isolate.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698