]> git.proxmox.com Git - mirror_edk2.git/commitdiff
edksetup.sh: Use bash variable $PWD instead of executing pwd command
authorrebecca@bsdio.com <rebecca@bsdio.com>
Tue, 16 Jul 2019 16:55:33 +0000 (10:55 -0600)
committerLaszlo Ersek <lersek@redhat.com>
Tue, 23 Jul 2019 08:41:55 +0000 (10:41 +0200)
This is a (very minor) optimization: `pwd` runs the command (even as a
built-in), whereas $PWD simply evaluates the value of the variable.

ALso, modern scripts should generally use $(...) to run commands,
instead of `...`.

Signed-off-by: Rebecca Cran <rebecca@bsdio.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
Reviewed-by: Leif Lindholm <leif.lindholm@linaro.org>
Message-Id: <20190716165538.57960-1-rebecca@bsdio.com>

edksetup.sh

index 12a3e26a67da553ec7949cfa79497b9a82a7d102..ab58fe4a6e448f94fd2c175920f5b1ff26113782 100755 (executable)
@@ -71,7 +71,7 @@ function SetWorkspace()
   #
   # Set $WORKSPACE
   #
-  export WORKSPACE=`pwd`
+  export WORKSPACE=$PWD
   return 0
 }