From 76162d3632fee53460cf0a32e5bb81f866435ed2 Mon Sep 17 00:00:00 2001 From: Yoni Weill Date: Sat, 30 Oct 2021 12:27:38 +0300 Subject: [PATCH] bash plugin: fix nounset error --- gitstatus/gitstatus.plugin.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gitstatus/gitstatus.plugin.sh b/gitstatus/gitstatus.plugin.sh index 9a75cb5f..d1939989 100644 --- a/gitstatus/gitstatus.plugin.sh +++ b/gitstatus/gitstatus.plugin.sh @@ -371,7 +371,7 @@ function gitstatus_query() { local req_id="$RANDOM.$RANDOM.$RANDOM.$RANDOM" if [[ -z "${GIT_DIR:-}" ]]; then - [[ "$dir" == /* ]] || dir="$(pwd -P)/$dir" || return + [[ "${dir-}" == /* ]] || dir="$(pwd -P)/${dir-}" || return elif [[ "$GIT_DIR" == /* ]]; then dir=:"$GIT_DIR" else