@matheusbsbs / matheus-bagliano / commits / 41f5d73391
Fork 0

git-checkout: fix "eval" used for merge labelling.

The symbolic notation of the fork point can contain whitespaces (e.g. "git checkout -m 'HEAD@{9 hours ago}'"). Quote strings properly when using eval to prepare GITHEAD_$new Signed-off-by: Junio C Hamano <junkio@cox.net>

Junio C Hamano committed Mar 14, 2007 at 09:48 UTC 41f5d73391e3fe5c4cb2829582b26a85930964d1
1 file changed +1 -1
git-checkout.sh
+1 -1
@@ -196,7 +196,7 @@ else
196 work=`git write-tree` &&
197 git read-tree --reset -u $new || exit
198
199 - eval GITHEAD_$new=${new_name:-${branch:-$new}} &&
199 + eval GITHEAD_$new='${new_name:-${branch:-$new}}' &&
200 eval GITHEAD_$work=local &&
201 export GITHEAD_$new GITHEAD_$work &&
202 git merge-recursive $old -- $new $work