| OLD | NEW |
| 1 #!/usr/bin/python | 1 #!/usr/bin/python |
| 2 | 2 |
| 3 # Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 3 # Copyright (c) 2010 The Chromium OS 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 """This module uprevs a given package's ebuild to the next revision.""" | 7 """This module uprevs a given package's ebuild to the next revision.""" |
| 8 | 8 |
| 9 | 9 |
| 10 import fileinput | 10 import fileinput |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 """ | 121 """ |
| 122 | 122 |
| 123 # TODO(sosa) - Add logic for buildbot to check whether other slaves have | 123 # TODO(sosa) - Add logic for buildbot to check whether other slaves have |
| 124 # completed and push this change only if they have. | 124 # completed and push this change only if they have. |
| 125 | 125 |
| 126 # Sanity check to make sure we're on a stabilizing branch before pushing. | 126 # Sanity check to make sure we're on a stabilizing branch before pushing. |
| 127 if not _CheckOnStabilizingBranch(): | 127 if not _CheckOnStabilizingBranch(): |
| 128 generate_test_report.Die('Expected %s to be on branch "%s"' % | 128 generate_test_report.Die('Expected %s to be on branch "%s"' % |
| 129 (_CHROMIUMOS_OVERLAYS_DIRECTORY, | 129 (_CHROMIUMOS_OVERLAYS_DIRECTORY, |
| 130 _STABLE_BRANCH_NAME)) | 130 _STABLE_BRANCH_NAME)) |
| 131 _RunCommand('git cl upload --desc_from_logs -m "%s"' % |
| 132 'Marking set of ebuilds as stable') |
| 131 _RunCommand('git cl push %s' % gflags.FLAGS.push_options) | 133 _RunCommand('git cl push %s' % gflags.FLAGS.push_options) |
| 132 | 134 |
| 133 | 135 |
| 134 def _RunCommand(command): | 136 def _RunCommand(command): |
| 135 """Runs a shell command and returns stdout back to caller.""" | 137 """Runs a shell command and returns stdout back to caller.""" |
| 136 _Print(' + %s' % command) | 138 _Print(' + %s' % command) |
| 137 proc_handle = subprocess.Popen(command, stdout=subprocess.PIPE, shell=True) | 139 proc_handle = subprocess.Popen(command, stdout=subprocess.PIPE, shell=True) |
| 138 return proc_handle.communicate()[0] | 140 return proc_handle.communicate()[0] |
| 139 | 141 |
| 140 | 142 |
| (...skipping 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 353 'and reset the git repo yourself.' % | 355 'and reset the git repo yourself.' % |
| 354 (package_list[:index], _CHROMIUMOS_OVERLAYS_DIRECTORY)) | 356 (package_list[:index], _CHROMIUMOS_OVERLAYS_DIRECTORY)) |
| 355 raise e | 357 raise e |
| 356 elif command == 'push': | 358 elif command == 'push': |
| 357 _PushChange() | 359 _PushChange() |
| 358 | 360 |
| 359 | 361 |
| 360 if __name__ == '__main__': | 362 if __name__ == '__main__': |
| 361 main(sys.argv) | 363 main(sys.argv) |
| 362 | 364 |
| OLD | NEW |