From c7c9647a0b0bbcf6115b885895207af3343d4835 Mon Sep 17 00:00:00 2001 From: Zhao Lei Date: Wed, 23 Sep 2015 18:49:26 +0800 Subject: [PATCH] Remove quotes from subshell call in bash script Always no quotes for $() statement. We don't need quotes to hold blanks in result: # i=$(echo 1 2 3) # echo $i 1 2 3 # These quotes can make something wrong in some case: # i=$(echo '!') # # i="$(echo '!')" -bash: !: event not found # No real problem for current code, only to use a better code style. Change-Id: I0f43bb936f956c99603dc15aaad9db851ecf0acd Signed-off-by: Zhao Lei --- tools/update_states.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/update_states.sh b/tools/update_states.sh index 60ca3d4b..61b54e8c 100755 --- a/tools/update_states.sh +++ b/tools/update_states.sh @@ -12,7 +12,7 @@ if [ ! -d "$PWD/.diagram-tools" ]; then git clone "https://github.com/vidarh/diagram-tools.git" "$PWD/.diagram-tools" fi -script_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" +script_dir=$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd ) img_dir="$script_dir/../doc/source/img" echo "---- Updating task state diagram ----"