Re: [PATCH] git-sh-setup.sh: make GIT_EDITOR/core.editor/VISUAL/EDITOR accept commands
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Aug 1, 2007, 23:21 UTC
- Message-ID
- <7vtzri3kpr.fsf@assigned-by-dhcp.cox.net>
- In-Reply-To
- <7vy7gu3kuh.fsf@assigned-by-dhcp.cox.net>
Junio C Hamano <gitster@pobox.com> writes:
> It is not just "won't apply". What if GIT_DIR had spaces (which > is fine) and single-quotes in it? Wouldn't it percolate down to > $@ because it becomes the leading directory of the temporary > file name? And you quote '"$@"' and eval it, now what happens?
Ah, I spoke too fast. It is fine --- the shell that actually is doing the eval then interpolates "$@". Clever.