Skip to content

Commit

Permalink
[misc] Improve format server stability (#672)
Browse files Browse the repository at this point in the history
Force delete when user reuses branch name
  • Loading branch information
yuanming-hu committed Mar 28, 2020
1 parent 675338b commit a05f93f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion misc/format_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ def do_GET(self):
ssh_url = head['repo']['ssh_url']
self.exec(f'git remote add {user_id} {ssh_url}')
self.exec(f'git fetch {user_id} {branch_name}')
self.exec(f'git branch -d {user_id}-{branch_name}')
self.exec(f'git branch -D {user_id}-{branch_name}')
self.exec(
f'git checkout -b {user_id}-{branch_name} {user_id}/{branch_name}')
commits = self.exec(
Expand Down

0 comments on commit a05f93f

Please sign in to comment.