git-stash.sh: use the $( ... ) construct for command substitution
The Git CodingGuidelines prefer the $(...) construct for command substitution instead of using the backquotes `...`. The backquoted form is the traditional method for command substitution, and is supported by POSIX. However, all but the simplest uses become complicated quickly. In particular, embedded command substitutions and/or the use of double quotes require careful escaping with the backslash character. The patch was generated by: for _f in $(find . -name "*.sh") do sed -i 's@`\(.*\)`@$(\1)@g' ${_f} done and then carefully proof-read. Signed-off-by: Elia Pinto <gitter.spiros@gmail.com> Reviewed-by: Matthieu Moy <Matthieu.Moy@imag.fr> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Elia Pinto committed
Apr 23, 2014 at 06:44 UTC
d0ea45bfc7129304016b24bdb18523b927d0ab17
1 file changed
+1
-1
git-stash.sh
+1
-1
@@ -13,7 +13,7 @@ USAGE="list [<options>]
13
14
SUBDIRECTORY_OK=Yes
15
OPTIONS_SPEC=
16
-START_DIR=`pwd`
16
+START_DIR=$(pwd)
17
. git-sh-setup
18
. git-sh-i18n
19
require_work_tree