Thread (1 message) 1 message, 1 author, 2016-06-15

Re: [PATCH 2/2] Quoting paths in tests

From: David Kastrup <hidden>
Date: 2016-06-15 22:43:42

David Kastrup [off-list ref] writes:
Jonathan del Strother [off-list ref] writes:
quoted
For instance, git_editor in git-sh-setup expects the editor path to be
pre-quoted.  So in t3404, you need to produce escaped double quotes &
dollar signs, resulting in unpleasantness like this :

VISUAL="`pwd`/fake-editor.sh"
VISUAL=${VISUAL//\"/\\\"}
VISUAL=${VISUAL//$/\\\$}
VISUAL=\"$VISUAL\"
export VISUAL
EDITORPWD="`pwd`"
VISUAL='$EDITORPWD/fake-editor.sh'
export EDITORPWD VISUAL
Pffffft.

VISUAL='"$EDITORPWD/fake-editor.sh"'

of course.  Or we still have problems with spaces in pwd.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help