clean: report branch's deletion failure instead of stopping
This commit is contained in:
parent
c58395944a
commit
e32cda0fba
|
@ -642,8 +642,12 @@ def clean():
|
|||
for _id, _subject in issues_to_delete:
|
||||
ref = issues_to_branch[str(_id)]
|
||||
click.echo('Deleting origin/%s... ' % ref, nl=False)
|
||||
origin.push(refspec=':%s' % ref)
|
||||
click.echo(click.style('Done.', fg='green'))
|
||||
try:
|
||||
origin.push(refspec=':%s' % ref)
|
||||
except git.GitCommandError as e:
|
||||
click.echo(click.style('Failed(%s).' % e, fg='red'))
|
||||
else:
|
||||
click.echo(click.style('Done.', fg='green'))
|
||||
|
||||
issues_to_branch = {}
|
||||
for ref in repo.branches:
|
||||
|
|
Loading…
Reference in New Issue