Commit 5b628e2d authored by Mario Trangoni's avatar Mario Trangoni

shellcheck: Fix SC2006 issue

See, $ find . -name "*.sh" | xargs shellcheck -i SC2006 In ./roll-tarballs.sh line 62: echo "HEAD (on branch `git rev-parse --abbrev-ref HEAD`)" ^-- SC2006: Use $(...) notation instead of legacy backticked `...`. Did you mean: echo "HEAD (on branch $(git rev-parse --abbrev-ref HEAD))" In ./nx-X11/x-indent-all.sh line 2: where=`dirname $0` ^----------^ SC2006: Use $(...) notation instead of legacy backticked `...`. Did you mean: where=$(dirname $0) In ./nx-X11/x-indent.sh line 5: INDENT=`which gnuindent || which gindent || which indent` ^-- SC2006: Use $(...) notation instead of legacy backticked `...`. Did you mean: INDENT=$(which gnuindent || which gindent || which indent) For more information: https://www.shellcheck.net/wiki/SC2006 -- Use $(...) notation instead of le... Signed-off-by: 's avatarMario Trangoni <mjtrangoni@gmail.com>
parent e5746df8
#!/bin/sh #!/bin/sh
where=`dirname $0` where=$(dirname $0)
git ls-files | grep '\.[chm]$' | xargs sh "$where"/x-indent.sh git ls-files | grep '\.[chm]$' | xargs sh "$where"/x-indent.sh
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
# We want GNU indent, so first search for gindent to avoid /usr/bin/indent # We want GNU indent, so first search for gindent to avoid /usr/bin/indent
# on the BSDs, which won't work for us # on the BSDs, which won't work for us
INDENT=`which gnuindent || which gindent || which indent` INDENT=$(which gnuindent || which gindent || which indent)
if [ -z "${INDENT}" ] ; then if [ -z "${INDENT}" ] ; then
echo "Could not find indent, sorry..." >&2 echo "Could not find indent, sorry..." >&2
......
...@@ -59,7 +59,7 @@ fi ...@@ -59,7 +59,7 @@ fi
if ! git rev-parse --verify -q "$CHECKOUT" >/dev/null; then if ! git rev-parse --verify -q "$CHECKOUT" >/dev/null; then
echo " '${RELEASE}' is not a valid release number because there is no git tag named ${CHECKOUT}." echo " '${RELEASE}' is not a valid release number because there is no git tag named ${CHECKOUT}."
echo " Please specify one of the following releases:" echo " Please specify one of the following releases:"
echo "HEAD (on branch `git rev-parse --abbrev-ref HEAD`)" echo "HEAD (on branch $(git rev-parse --abbrev-ref HEAD))"
git tag -l | grep "^redist" | cut -f2 -d"/" | sort -u git tag -l | grep "^redist" | cut -f2 -d"/" | sort -u
exit 1 exit 1
fi fi
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment