Skip to content

Commit

Permalink
Make git-pr set up branch for pulling (#570)
Browse files Browse the repository at this point in the history
With these changes, the pr/nn branches created by git-pr also support `git pull` to get PR updates.
  • Loading branch information
rmartinho authored and hemanth committed Sep 11, 2016
1 parent 93c2830 commit 241069d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion bin/git-pr
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,7 @@ else
id=$1
branch=pr/$id
fi
git fetch -fu $remote refs/pull/$id/head:$branch && git checkout $branch
git fetch -fu $remote refs/pull/$id/head:$branch && \
git checkout $branch && \
git config --local --replace branch.\"$branch\".merge refs/pull/$id/head && \
git config --local --replace branch.\"$branch\".remote $remote;

0 comments on commit 241069d

Please sign in to comment.