summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 2be7fcb)
raw | patch | inline | side by side (parent: 2be7fcb)
author | Junio C Hamano <gitster@pobox.com> | |
Mon, 20 Aug 2007 22:35:15 +0000 (15:35 -0700) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 20 Aug 2007 22:35:15 +0000 (15:35 -0700) |
Unless the user explicitly asked hardlinking with the '-l'
option, we should not say "oops we cannot hardlink as you asked
so we are copying".
Signed-off-by: Junio C Hamano <gitster@pobox.com>
option, we should not say "oops we cannot hardlink as you asked
so we are copying".
Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-clone.sh | patch | blob | history |
diff --git a/git-clone.sh b/git-clone.sh
index e4a9ac4babcb0d0b3c2f9aac48925a18cd71f61f..18003ab4b39ad0a7848cc20db2f6ad55e1291264 100755 (executable)
--- a/git-clone.sh
+++ b/git-clone.sh
use_separate_remote=t
depth=
no_progress=
+local_explicitly_asked_for=
test -t 1 || no_progress=--no-progress
while
case "$#,$1" in
*,--na|*,--nak|*,--nake|*,--naked|\
*,-b|*,--b|*,--ba|*,--bar|*,--bare) bare=yes ;;
*,-l|*,--l|*,--lo|*,--loc|*,--loca|*,--local)
+ local_explicitly_asked_for=yes
use_local_hardlink=yes ;;
*,--no-h|*,--no-ha|*,--no-har|*,--no-hard|*,--no-hardl|\
*,--no-hardli|*,--no-hardlin|*,--no-hardlink|*,--no-hardlinks)
then
rm -f "$GIT_DIR/objects/sample"
l=l
- else
+ elif test -n "$local_explicitly_asked_for"
+ then
echo >&2 "Warning: -l asked but cannot hardlink to $repo"
fi
fi &&