From: Santi_Béjar Date: Wed, 5 Oct 2005 16:58:10 +0000 (+0200) Subject: [PATCH] Quote the missing GIT_DIR. X-Git-Tag: v0.99.8b~1^2~3 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=df34297af1fe5da786e41bd2fee58e10dd810cc4;p=git.git [PATCH] Quote the missing GIT_DIR. Signed-off-by: Santi Béjar Signed-off-by: Junio C Hamano --- diff --git a/git-commit.sh b/git-commit.sh index 5e85b546..591fcdce 100755 --- a/git-commit.sh +++ b/git-commit.sh @@ -198,7 +198,7 @@ else PARENTS="" fi git-status >>.editmsg -if [ "$?" != "0" -a ! -f $GIT_DIR/MERGE_HEAD ] +if [ "$?" != "0" -a ! -f "$GIT_DIR/MERGE_HEAD" ] then rm -f .editmsg git-status diff --git a/git-fetch.sh b/git-fetch.sh index 61da6a9e..d3988660 100755 --- a/git-fetch.sh +++ b/git-fetch.sh @@ -49,7 +49,7 @@ rsync_slurped_objects= if test "" = "$append" then - : >$GIT_DIR/FETCH_HEAD + : >"$GIT_DIR/FETCH_HEAD" fi append_fetch_head () { @@ -86,11 +86,11 @@ append_fetch_head () { if git-cat-file commit "$head_" >/dev/null 2>&1 then headc_=$(git-rev-parse --verify "$head_^0") || exit - echo "$headc_ $not_for_merge_ $note_" >>$GIT_DIR/FETCH_HEAD + echo "$headc_ $not_for_merge_ $note_" >>"$GIT_DIR/FETCH_HEAD" echo >&2 "* committish: $head_" echo >&2 " $note_" else - echo "$head_ not-for-merge $note_" >>$GIT_DIR/FETCH_HEAD + echo "$head_ not-for-merge $note_" >>"$GIT_DIR/FETCH_HEAD" echo >&2 "* non-commit: $head_" echo >&2 " $note_" fi