From d254dc6b7fa12b4d8228d384cc2c63e11769f8c9 Mon Sep 17 00:00:00 2001 From: Chris King-Parra Date: Wed, 28 Feb 2018 11:15:55 -0500 Subject: [PATCH] Quote parameter substitutions and command substitutions in build_version() of bin/kaleidoscope-builder. Issue #299. --- bin/kaleidoscope-builder | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bin/kaleidoscope-builder b/bin/kaleidoscope-builder index 6f5fb38c..f2c441dc 100755 --- a/bin/kaleidoscope-builder +++ b/bin/kaleidoscope-builder @@ -7,10 +7,10 @@ set -e ###### build_version () { - GIT_VERSION="$(cd $(find_sketch); git describe --abbrev=4 --dirty --always)" - LIB_VERSION="$(cd $(find_sketch); (grep version= ../../library.properties 2>/dev/null || echo version=0.0.0) | cut -d= -f2)-g${GIT_VERSION}" + GIT_VERSION="$(cd "$(find_sketch)"; git describe --abbrev=4 --dirty --always)" + LIB_VERSION="$(cd "$(find_sketch)"; (grep version= ../../library.properties 2>/dev/null || echo version=0.0.0) | cut -d= -f2)-g${GIT_VERSION}" - BUILD_PATH="${BUILD_PATH:-$(mktemp -d 2>/dev/null || mktemp -d -t 'build')}" + BUILD_PATH="${BUILD_PATH:-"$(mktemp -d 2>/dev/null || mktemp -d -t 'build')"}" OUTPUT_DIR="${OUTPUT_DIR:-output/${LIBRARY}}" OUTPUT_PATH="${OUTPUT_PATH:-${SOURCEDIR}/${OUTPUT_DIR}}" }