summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: d4ebc36)
raw | patch | inline | side by side (parent: d4ebc36)
author | Josef Weidendorfer <Josef.Weidendorfer@gmx.de> | |
Tue, 19 Dec 2006 00:39:07 +0000 (01:39 +0100) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Tue, 19 Dec 2006 09:53:02 +0000 (01:53 -0800) |
The warning triggered even when running "git fetch" only
when resulting .git/FETCH_HEAD only contained
branches marked as 'not-for-merge'.
Signed-off-by: Josef Weidendorfer <weidendo@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
when resulting .git/FETCH_HEAD only contained
branches marked as 'not-for-merge'.
Signed-off-by: Josef Weidendorfer <weidendo@gmx.de>
Signed-off-by: Junio C Hamano <junkio@cox.net>
git-parse-remote.sh | patch | blob | history | |
git-pull.sh | patch | blob | history |
diff --git a/git-parse-remote.sh b/git-parse-remote.sh
index 11c4aba24448492f1ba1836cded54170a5dde08c..ea7511e8a0f18a3402146ce8acc1c051fc92475f 100755 (executable)
--- a/git-parse-remote.sh
+++ b/git-parse-remote.sh
# or the first one otherwise; add prefix . to the rest
# to prevent the secondary branches to be merged by default.
merge_branches=
- found_mergeref=
curr_branch=
if test "$1" = "-d"
then
dot_prefix= && break
done
fi
- if test -z $dot_prefix
- then
- found_mergeref=true
- fi
case "$remote" in
'') remote=HEAD ;;
refs/heads/* | refs/tags/* | refs/remotes/*) ;;
fi
echo "${dot_prefix}${force}${remote}:${local}"
done
- if test -z "$found_mergeref" -a "$curr_branch"
- then
- echo >&2 "Warning: No merge candidate found because value of config option
- \"branch.${curr_branch}.merge\" does not match any remote branch fetched."
- fi
}
# Returns list of src: (no store), or src:dst (store)
diff --git a/git-pull.sh b/git-pull.sh
index e23beb685d15447ac114c58d1795ed15bef88c9d..1703091bbb988e22f39b2c8d4c70ec7340a2f109 100755 (executable)
--- a/git-pull.sh
+++ b/git-pull.sh
case "$merge_head" in
'')
+ curr_branch=$(git-symbolic-ref HEAD | \
+ sed -e 's|^refs/heads/||')
+ echo >&2 "Warning: No merge candidate found because value of config option
+ \"branch.${curr_branch}.merge\" does not match any remote branch fetched."
echo >&2 "No changes."
exit 0
;;