Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Side by Side Diff: sitescripts/extensions/bin/createNightlies.py

Issue 29753611: Noissue - Remove fallback for old buildtools version (Closed)
Patch Set: Created April 16, 2018, 4:53 p.m.
Left:
Right:
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | 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 # This file is part of the Adblock Plus web scripts, 1 # This file is part of the Adblock Plus web scripts,
2 # Copyright (C) 2006-present eyeo GmbH 2 # Copyright (C) 2006-present eyeo GmbH
3 # 3 #
4 # Adblock Plus is free software: you can redistribute it and/or modify 4 # Adblock Plus is free software: you can redistribute it and/or modify
5 # it under the terms of the GNU General Public License version 3 as 5 # it under the terms of the GNU General Public License version 3 as
6 # published by the Free Software Foundation. 6 # published by the Free Software Foundation.
7 # 7 #
8 # Adblock Plus is distributed in the hope that it will be useful, 8 # Adblock Plus is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of 9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
(...skipping 332 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 if os.path.exists(self.path): 343 if os.path.exists(self.path):
344 os.remove(self.path) 344 os.remove(self.path)
345 raise 345 raise
346 else: 346 else:
347 env = os.environ 347 env = os.environ
348 spiderMonkeyBinary = self.config.spiderMonkeyBinary 348 spiderMonkeyBinary = self.config.spiderMonkeyBinary
349 if spiderMonkeyBinary: 349 if spiderMonkeyBinary:
350 env = dict(env, SPIDERMONKEY_BINARY=spiderMonkeyBinary) 350 env = dict(env, SPIDERMONKEY_BINARY=spiderMonkeyBinary)
351 351
352 command = [os.path.join(self.tempdir, 'build.py')] 352 command = [os.path.join(self.tempdir, 'build.py')]
353 if self.config.type == 'safari': 353 command.extend(['build', '-t', self.config.type, '-b',
354 command.extend(['-t', self.config.type, 'build']) 354 self.buildNum])
355 else:
356 command.extend(['build', '-t', self.config.type])
357 command.extend(['-b', self.buildNum])
358 355
359 if self.config.type not in {'gecko', 'edge'}: 356 if self.config.type not in {'gecko', 'edge'}:
360 command.extend(['-k', self.config.keyFile]) 357 command.extend(['-k', self.config.keyFile])
361 command.append(self.path) 358 command.append(self.path)
362 subprocess.check_call(command, env=env) 359 subprocess.check_call(command, env=env)
363 360
364 if not os.path.exists(self.path): 361 if not os.path.exists(self.path):
365 raise Exception("Build failed, output file hasn't been created") 362 raise Exception("Build failed, output file hasn't been created")
366 363
367 if self.config.type not in self.downloadable_repos: 364 if self.config.type not in self.downloadable_repos:
(...skipping 521 matching lines...) Expand 10 before | Expand all | Expand 10 after
889 886
890 file = open(nightlyConfigFile, 'wb') 887 file = open(nightlyConfigFile, 'wb')
891 nightlyConfig.write(file) 888 nightlyConfig.write(file)
892 889
893 890
894 if __name__ == '__main__': 891 if __name__ == '__main__':
895 parser = argparse.ArgumentParser() 892 parser = argparse.ArgumentParser()
896 parser.add_argument('--download', action='store_true', default=False) 893 parser.add_argument('--download', action='store_true', default=False)
897 args = parser.parse_args() 894 args = parser.parse_args()
898 main(args.download) 895 main(args.download)
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld