You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by ch...@apache.org on 2021/11/04 07:40:58 UTC

[apisix-dashboard] branch master updated: refactor: lint shell for shellcheck (#2193)

This is an automated email from the ASF dual-hosted git repository.

chenjunxu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/apisix-dashboard.git


The following commit(s) were added to refs/heads/master by this push:
     new 5510ecb  refactor: lint shell for shellcheck (#2193)
5510ecb is described below

commit 5510ecb1b94f93a688045ab1ecca1c8a0d15c935
Author: Yu.Bozhong <y....@foxmail.com>
AuthorDate: Thu Nov 4 15:40:51 2021 +0800

    refactor: lint shell for shellcheck (#2193)
---
 api/build.sh             | 2 +-
 api/run.sh               | 4 ++--
 api/test/docker/setup.sh | 4 ++--
 3 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/api/build.sh b/api/build.sh
index f160111..f3b9652 100755
--- a/api/build.sh
+++ b/api/build.sh
@@ -30,7 +30,7 @@ fi
 
 set -x
 export ENV=local
-pwd=`pwd`
+pwd=$(pwd)
 
 rm -rf output && mkdir -p output/conf && mkdir -p output/dag-to-lua
 
diff --git a/api/run.sh b/api/run.sh
index b7b3a2f..71eae44 100755
--- a/api/run.sh
+++ b/api/run.sh
@@ -17,8 +17,8 @@
 #
 
 export ENV=local
-pwd=`pwd`
+pwd=$(pwd)
 
-cd ./output
+cd ./output || exit
 
 exec ./manager-api
diff --git a/api/test/docker/setup.sh b/api/test/docker/setup.sh
index c328f82..50d60ea 100755
--- a/api/test/docker/setup.sh
+++ b/api/test/docker/setup.sh
@@ -17,7 +17,7 @@
 #
 
 #Executes commands from the intended directory "/api/test/docker".
-cd $(dirname $0)
+cd "$(dirname "$0")"
 
 main() {
   #welcome message & check machine configuration
@@ -57,7 +57,7 @@ main() {
   done
 
   if [ $UP -eq 1 ]; then
-    up $UPFLAG
+    up "$UPFLAG"
   fi
   echo "Execution complete."
 }