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

Unified Diff: tools/skp/recreate_skps.py

Issue 1665803002: Do not upload to trusted partner's bucket if it is a dry run (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: Initial upload Created 4 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/skp/recreate_skps.py
diff --git a/tools/skp/recreate_skps.py b/tools/skp/recreate_skps.py
index 46412771309d5052bddeedbd954a8b39faf728e3..b7ca07a9a7e559aa9ddda8c6e2c20486af8d666d 100644
--- a/tools/skp/recreate_skps.py
+++ b/tools/skp/recreate_skps.py
@@ -36,8 +36,9 @@ def _get_skp_version():
new_version += 1
-def main(chrome_src_path, browser_executable):
+def main(chrome_src_path, browser_executable, dry_run):
browser_executable = os.path.realpath(browser_executable)
+ dry_run = (dry_run == 'True')
skp_version = _get_skp_version()
print 'SKP_VERSION=%d' % skp_version
@@ -58,10 +59,11 @@ def main(chrome_src_path, browser_executable):
'--browser_executable', browser_executable,
'--non-interactive',
'--upload',
- '--upload_to_partner_bucket',
'--alternate_upload_dir', upload_dir,
'--chrome_src_path', chrome_src_path,
]
+ if not dry_run:
+ webpages_playback_cmd.append('--upload_to_partner_bucket')
try:
shell_utils.run(webpages_playback_cmd)
@@ -87,7 +89,8 @@ def main(chrome_src_path, browser_executable):
if '__main__' == __name__:
- if len(sys.argv) != 3:
- print >> sys.stderr, 'USAGE: %s <chrome src path> <browser executable>'
+ if len(sys.argv) != 4:
+ print >> sys.stderr, ('USAGE: %s <chrome src path> <browser executable> '
+ '<dry run>')
borenet 2016/02/03 13:06:34 Why not --upload_to_partner_bucket?
rmistry 2016/02/03 13:09:28 I think it will be useful to have information whet
borenet 2016/02/03 13:12:02 Okay, I thought dry run meant that we didn't uploa
borenet 2016/02/03 13:23:34 Ah, got it, thanks.
sys.exit(1)
main(*sys.argv[1:])
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698