Skip to content

Commit ba564bf

Browse files
authored
update cmd (#8)
1 parent ffeb832 commit ba564bf

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

cherry_picker.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,10 @@ def cherry_pick(commit_sha1, branches):
3333
run_cmd(cmd)
3434

3535
cmd = f"git branch -D {commit_sha1[:7]}-{branch}"
36-
run_cmd(cmd)
37-
click.echo(f"branch {commit_sha1[:7]}-{branch} has been deleted.")
36+
if run_cmd(cmd):
37+
click.echo(f"branch {commit_sha1[:7]}-{branch} has been deleted.")
38+
else:
39+
click.echo(f"branch {commit_sha1[:7]}-{branch} NOT deleted.")
3840

3941

4042
def get_git_upstream_remote():

0 commit comments

Comments
 (0)