| OLD | NEW |
| 1 #!/usr/bin/python | 1 #!/usr/bin/python |
| 2 | 2 |
| 3 # Copyright (c) 2014 The Chromium Authors. All rights reserved. | 3 # Copyright (c) 2014 The Chromium Authors. All rights reserved. |
| 4 # Use of this source code is governed by a BSD-style license that can be | 4 # Use of this source code is governed by a BSD-style license that can be |
| 5 # found in the LICENSE file. | 5 # found in the LICENSE file. |
| 6 | 6 |
| 7 """Steps to archive dartium, content_shell, and chromedriver from buildbots. | 7 """Steps to archive dartium, content_shell, and chromedriver from buildbots. |
| 8 | 8 |
| 9 Imported by buildbot_annotated_steps.py and multivm_archive.py | 9 Imported by buildbot_annotated_steps.py and multivm_archive.py |
| 10 """ | 10 """ |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 83 drt_bucket = dartium_bucket.replace('dartium', 'drt') | 83 drt_bucket = dartium_bucket.replace('dartium', 'drt') |
| 84 chromedriver_bucket = dartium_bucket.replace('dartium', 'chromedriver') | 84 chromedriver_bucket = dartium_bucket.replace('dartium', 'chromedriver') |
| 85 dartium_archive = dartium_bucket + '-' + info.version | 85 dartium_archive = dartium_bucket + '-' + info.version |
| 86 drt_archive = drt_bucket + '-' + info.version | 86 drt_archive = drt_bucket + '-' + info.version |
| 87 chromedriver_archive = chromedriver_bucket + '-' + info.version | 87 chromedriver_archive = chromedriver_bucket + '-' + info.version |
| 88 dartium_zip, drt_zip, chromedriver_zip = archive.Archive( | 88 dartium_zip, drt_zip, chromedriver_zip = archive.Archive( |
| 89 SRC_PATH, | 89 SRC_PATH, |
| 90 info.mode, | 90 info.mode, |
| 91 dartium_archive, | 91 dartium_archive, |
| 92 drt_archive, | 92 drt_archive, |
| 93 chromedriver_archive, | 93 chromedriver_archive) |
| 94 is_win_ninja=False) | |
| 95 | 94 |
| 96 status = 0 | 95 status = 0 |
| 97 # Upload bleeding-edge builds to old dartium-archive bucket | 96 # Upload bleeding-edge builds to old dartium-archive bucket |
| 98 if info.channel == 'be': | 97 if info.channel == 'be': |
| 99 status = (OldUpload('dartium', dartium_bucket, | 98 status = (OldUpload('dartium', dartium_bucket, |
| 100 os.path.abspath(dartium_zip), | 99 os.path.abspath(dartium_zip), |
| 101 archive_latest=archive_latest) | 100 archive_latest=archive_latest) |
| 102 or OldUpload('drt', drt_bucket, | 101 or OldUpload('drt', drt_bucket, |
| 103 os.path.abspath(drt_zip), | 102 os.path.abspath(drt_zip), |
| 104 archive_latest=archive_latest) | 103 archive_latest=archive_latest) |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 def RemoveArchives(archives): | 269 def RemoveArchives(archives): |
| 271 """Remove the list of archives in Google storage. | 270 """Remove the list of archives in Google storage. |
| 272 """ | 271 """ |
| 273 for archive in archives: | 272 for archive in archives: |
| 274 if archive.find(GS_SITE) == 0: | 273 if archive.find(GS_SITE) == 0: |
| 275 cmd = [GSUTIL, 'rm', archive.rstrip()] | 274 cmd = [GSUTIL, 'rm', archive.rstrip()] |
| 276 (status, _) = ExecuteCommand(cmd) | 275 (status, _) = ExecuteCommand(cmd) |
| 277 if status != 0: | 276 if status != 0: |
| 278 return status | 277 return status |
| 279 return 0 | 278 return 0 |
| OLD | NEW |