diff options
author | Junio C Hamano <junkio@cox.net> | 2006-12-24 01:59:53 -0800 |
---|---|---|
committer | Junio C Hamano <junkio@cox.net> | 2006-12-24 02:18:57 -0800 |
commit | 80c797764a6b6a373f0f1f47d7f56b0d950418a9 (patch) | |
tree | a9e9b864fb4bb051f87c6b0bb5985122b5dc1868 /git-parse-remote.sh | |
parent | e036c90a913889dfa8097ebe73b619370e0c6f32 (diff) | |
download | git-80c797764a6b6a373f0f1f47d7f56b0d950418a9.tar.gz git-80c797764a6b6a373f0f1f47d7f56b0d950418a9.tar.xz |
Allow branch.*.merge to talk about remote tracking branches.
People often get confused if the value of branch.*.merge should
be the remote branch name they are fetching from, or the
tracking branch they locally have. So this allows either.
Signed-off-by: Junio C Hamano <junkio@cox.net>
Diffstat (limited to 'git-parse-remote.sh')
-rwxr-xr-x | git-parse-remote.sh | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/git-parse-remote.sh b/git-parse-remote.sh index aaef861ad..144f17015 100755 --- a/git-parse-remote.sh +++ b/git-parse-remote.sh @@ -146,8 +146,12 @@ canon_refs_list_for_fetch () { else for merge_branch in $merge_branches do - [ "$remote" = "$merge_branch" ] && - dot_prefix= && break + if test "$remote" = "$merge_branch" || + test "$local" = "$merge_branch" + then + dot_prefix= + break + fi done fi case "$remote" in |