From 32efe0a04f04187fbcb8369da7a53f3fff9a9204 Mon Sep 17 00:00:00 2001 From: Andres Gongora Date: Sat, 18 Apr 2020 11:40:28 +0200 Subject: [PATCH] Update include statement Signed-off-by: Andres Gongora --- bash-tools | 2 +- synth-shell-prompt/synth-shell-prompt.sh | 11 +++++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/bash-tools b/bash-tools index 03b1ef5..32cc7c7 160000 --- a/bash-tools +++ b/bash-tools @@ -1 +1 @@ -Subproject commit 03b1ef5e16faffe38cab94dc8a7d7bf58015e95d +Subproject commit 32cc7c7a299cf82412bacbdac38feb1947531b49 diff --git a/synth-shell-prompt/synth-shell-prompt.sh b/synth-shell-prompt/synth-shell-prompt.sh index cdfba57..eac188a 100755 --- a/synth-shell-prompt/synth-shell-prompt.sh +++ b/synth-shell-prompt/synth-shell-prompt.sh @@ -36,14 +36,21 @@ ## ## -## INCLUDE() -[ "$(type -t include)"!='function' ]&&{ include(){ { [ -z "$_IR" ]&&_IR="$PWD"&&cd $(dirname "${BASH_SOURCE[0]}")&&include "$1"&&cd "$_IR"&&unset _IR;}||{ local d=$PWD&&cd "$(dirname "$PWD/$1")"&&. "$(basename "$1")"&&cd "$d";}||{ echo "Include failed $PWD->$1"&&exit 1;};};} + + +##============================================================================== +## EXTERNAL DEPENDENCIES +##============================================================================== +[ "$(type -t include)" != 'function' ]&&{ include(){ { [ -z "$_IR" ]&&_IR="$PWD"&&cd $(dirname "${BASH_SOURCE[0]}")&&include "$1"&&cd "$_IR"&&unset _IR;}||{ local d=$PWD&&cd "$(dirname "$PWD/$1")"&&. "$(basename "$1")"&&cd "$d";}||{ echo "Include failed $PWD->$1"&&exit 1;};};} include '../bash-tools/bash-tools/color.sh' include '../config/synth-shell-prompt.config' + + + synth_shell_prompt() {