From d8fd929d463edc0f8d68eb76d1ce4c152b39f445 Mon Sep 17 00:00:00 2001 From: merakor Date: Tue, 14 Apr 2020 19:03:54 +0000 Subject: kiss: use the upper directory for KISS_PATH if no argument is specified FossilOrigin-Name: 550011c996d5f7da3cfea6c4fadf020fbe4382eef307ee7edf258655978de47f --- kiss | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/kiss b/kiss index 9053c2c..727829c 100755 --- a/kiss +++ b/kiss @@ -1263,7 +1263,13 @@ args() { case $action in b|build|c|checksum|i|install|r|remove) - [ "$1" ] || set -- "${PWD##*/}" ; esac + [ "$1" ] || { + # We are exporting the KISS_PATH, so if another + # instance of 'kiss' is spawned from the current + # one, they continue to use the same KISS_PATH + export KISS_PATH="${PWD%/*}" + set -- "${PWD##*/}" + } ; esac # Actions can be abbreviated to their first letter. This saves # keystrokes once you memorize the commands. -- cgit v1.2.3