7 if [ "$2" = "tag" ]; then
8 merge_name
="refs/tags/$3"
9 destination
="$merge_name"
13 : ${GIT_OBJECT_DIRECTORY="${SHA1_FILE_DIRECTORY-"$GIT_DIR/objects"}"}
14 TMP_HEAD
="$GIT_DIR/TMP_HEAD"
18 head=$
(wget
-q -O - "$merge_repo/$merge_name") ||
exit 1
19 echo Fetching
$head using http
20 git-http-pull
-v -a "$head" "$merge_repo/"
23 rsync
-L "$merge_repo/$merge_name" "$TMP_HEAD" ||
exit 1
24 head=$
(git-rev-parse TMP_HEAD
)
26 rsync
-avz --ignore-existing "$merge_repo/objects/" "$GIT_OBJECT_DIRECTORY/"
29 head=$
(git-fetch-pack
"$merge_repo" "$merge_name")
32 git-rev-parse
--verify "$head" > /dev
/null ||
exit 1
33 echo "$head" > "$GIT_DIR/$destination"