Permalink
Browse files

Unbreaking delete all

  • Loading branch information...
craveytrain committed Sep 13, 2013
1 parent 4006a58 commit 9277d82ba7c22d54ae1b47da642504009feb7e36
Showing with 12 additions and 9 deletions.
  1. +12 −9 bin/git-scrub
View
@@ -32,16 +32,19 @@ def main():
stdout, stderr = call_command('git branch -d %s' % branch)
print stdout
- if 'not fully merged' in stderr and delete_all is False:
- print stderr.splitlines()[0]
- override = raw_input('Delete %s branch with prejudice? (Y, N, A)' % branch)
- if override in ['A', 'a']:
- delete_all = True
- delete_local_branch(branch)
- elif override in ['Y', 'y']:
- delete_local_branch(branch)
+ if 'not fully merged' in stderr:
+ if delete_all is True:
+ delete_local_branch(bran)
else:
- print '%s branch skipped' % branch
+ print stderr.splitlines()[0]
+ override = raw_input('Delete %s branch with prejudice? (Y, N, A)' % branch)
+ if override in ['A', 'a']:
+ delete_all = True
+ delete_local_branch(branch)
+ elif override in ['Y', 'y']:
+ delete_local_branch(branch)
+ else:
+ print '%s branch skipped' % branch
def delete_local_branch(branch):

0 comments on commit 9277d82

Please sign in to comment.