diff options
author | merakor <cem@ckyln.com> | 2020-04-14 19:03:54 +0000 |
---|---|---|
committer | merakor <cem@ckyln.com> | 2020-04-14 19:03:54 +0000 |
commit | d8fd929d463edc0f8d68eb76d1ce4c152b39f445 (patch) | |
tree | cb6cbcfaa653d69ef109faa349a0c6b18660ba87 /kiss | |
parent | 6b833795edb8db83b2a786cf3c8209ec95d4b87d (diff) | |
download | cpt-d8fd929d463edc0f8d68eb76d1ce4c152b39f445.tar.gz |
kiss: use the upper directory for KISS_PATH if no argument is specified
FossilOrigin-Name: 550011c996d5f7da3cfea6c4fadf020fbe4382eef307ee7edf258655978de47f
Diffstat (limited to 'kiss')
-rwxr-xr-x | kiss | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -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. |