Add restore messages to gerrit auto-expire script
Fixes bug #950497 Change-Id: Ib7c1eb134d21883c6d02987cceb3823c59f90abe
This commit is contained in:
parent
813c033198
commit
68e3619c1f
@ -40,9 +40,9 @@ ssh.connect('localhost', username=GERRIT_USER, key_filename=GERRIT_SSH_KEY, port
|
|||||||
|
|
||||||
def expire_patch_set(patch_id, patch_subject, has_negative):
|
def expire_patch_set(patch_id, patch_subject, has_negative):
|
||||||
if has_negative:
|
if has_negative:
|
||||||
message= 'code review expired after 1 week of no activity after a negative review'
|
message= 'code review expired after 1 week of no activity after a negative review, it can be restored using the \`Restore Change\` button above'
|
||||||
else:
|
else:
|
||||||
message= 'code review expired after 2 weeks of no activity'
|
message= 'code review expired after 2 weeks of no activity, it can be restored using the \`Restore Change\` button above'
|
||||||
command='gerrit review --abandon --message="{0}" {1}'.format(message, patch_id)
|
command='gerrit review --abandon --message="{0}" {1}'.format(message, patch_id)
|
||||||
logger.info('Expiring: %s - %s: %s', patch_id, patch_subject, message)
|
logger.info('Expiring: %s - %s: %s', patch_id, patch_subject, message)
|
||||||
stdin, stdout, stderr = ssh.exec_command(command)
|
stdin, stdout, stderr = ssh.exec_command(command)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user