clone: keep --reference even with -l -s

Both -l -s and --reference update objects/info/alternates and used
to write over each other.

Signed-off-by: Martin Waitz <tali@admingilde.org>
Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
Martin Waitz
2006-05-07 20:19:09 +02:00
committed by Junio C Hamano
parent 6fe31e2e4c
commit cf9dc65368
2 changed files with 79 additions and 1 deletions

View File

@ -265,7 +265,7 @@ yes,yes)
test -f "$repo/objects/info/alternates" &&
cat "$repo/objects/info/alternates";
echo "$repo/objects"
} >"$GIT_DIR/objects/info/alternates"
} >>"$GIT_DIR/objects/info/alternates"
;;
esac
git-ls-remote "$repo" >"$GIT_DIR/CLONE_HEAD"