Skip to content

Commit

Permalink
Merge pull request ceph#18157 from batrick/ptl-tool-branch-checkout
Browse files Browse the repository at this point in the history
ptl-tool: checkout branch after creation

Reviewed-by: Jos Collin <[email protected]>
  • Loading branch information
joscollin authored Oct 9, 2017
2 parents 96ddf5c + ae5d61b commit 2953986
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions src/script/ptl-tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,16 +231,8 @@ def build_branch(args):
if branch == 'HEAD':
log.info("Leaving HEAD detached; no branch anchors your commits")
else:
# Delete test branch if it already existed
try:
getattr(G.branches, branch).delete(
G, getattr(G.branches, branch), force=True)
log.info("Deleted old test branch %s" % branch)
except AttributeError:
pass

G.create_head(branch)
log.info("Created branch {branch}".format(branch=branch))
G.head.reference = G.create_head(branch, force=True)
log.info("Checked out new branch {branch}".format(branch=branch))

# tag it for future reference.
for i in range(0, 100):
Expand Down

0 comments on commit 2953986

Please sign in to comment.