##// END OF EJS Templates
use check_call for git add and commit...
MinRK -
Show More
@@ -70,22 +70,14 b" def backport_pr(branch, num, project='ipython/ipython'):"
70
70
71 filenames = [ f['filename'] for f in files ]
71 filenames = [ f['filename'] for f in files ]
72
72
73 add = Popen(['git', 'add'] + filenames)
73 check_call(['git', 'add'] + filenames)
74 add.wait()
74
75 if add.returncode:
75 check_call(['git', 'commit', '-m', msg])
76 print("add failed!")
76
77 return 1
77 print("PR #%i applied, with msg:" % num)
78
78 print()
79 commit = Popen(['git', 'commit', '-m', msg])
79 print(msg)
80 commit.wait()
80 print()
81 if commit.returncode:
82 print("commit failed!")
83 return 1
84 else:
85 print("PR #%i applied, with msg:" % num)
86 print()
87 print(msg)
88 print()
89
81
90 if branch != current_branch:
82 if branch != current_branch:
91 check_call(['git', 'checkout', current_branch])
83 check_call(['git', 'checkout', current_branch])
General Comments 0
You need to be logged in to leave comments. Login now