From b72744841fda75200ed72ede41d869e83a9972ce Mon Sep 17 00:00:00 2001 From: Patrick McDermott Date: Sat, 13 Apr 2019 20:57:09 -0400 Subject: main(): Improve in-place detection --- diff --git a/src/main.sh b/src/main.sh index f8b4cc5..2fbbdbf 100644 --- a/src/main.sh +++ b/src/main.sh @@ -46,9 +46,9 @@ main() local cmd= local status= - if [ -f "${0%/*}/.builddirstamp" ]; then + if [ -f "$(dirname "${0}")/.builddirstamp" ]; then in_place=true - builddir="${0%/*}" + builddir="$(dirname "${0}")" else in_place=false builddir='' -- cgit v0.9.1