From 47287f3b218e7f30e2ce5b1bdd7f6b0f3fac41ee Mon Sep 17 00:00:00 2001 From: Ben Sima Date: Thu, 16 Dec 2021 07:57:39 -0500 Subject: Add hoog.sh, improve ide scripts --- Biz/Ide/ns | 65 +++++++++++++++++++++++++++++++------------------------------- 1 file changed, 33 insertions(+), 32 deletions(-) (limited to 'Biz/Ide/ns') diff --git a/Biz/Ide/ns b/Biz/Ide/ns index 6d27d46..aa4beac 100755 --- a/Biz/Ide/ns +++ b/Biz/Ide/ns @@ -1,33 +1,34 @@ #!/usr/bin/env bash - -if [[ $NOUN == "" ]] -then - export NOUN=$(fd --exclude=_ -t f . $BIZ_ROOT | fzf) -fi - -if [[ $VERB == "" ]] -then - export VERB=$(fzf <<< $(sed 's/ /\n/g' <<< "edit bild push ship lint")) -fi - -$VERB $NOUN - -printf "\nn:\tchange ns\nv:\tchange verb\nb:\tchange both\n^C:\texit\nelse:\tcontinue\n" -read -p " ns> " -n 1 input - -if [[ $input == "v" ]] -then - unset VERB - $0 -elif [[ $input == "n" ]] -then - unset NOUN - $0 -elif [[ $input == "b" ]] -then - unset NOUN - unset VERB - $0 -else - $0 -fi +## + if [[ $NOUN == "" ]] + then + export NOUN=$(fd --exclude=_ -t f . $BIZ_ROOT | fzf) + fi +## + if [[ $VERB == "" ]] + then + export VERB=$(fzf <<< $(sed 's/ /\n/g' <<< "edit bild push ship lint")) + fi +## + $VERB $NOUN +## + printf "\nn:\tchange ns\nv:\tchange verb\nb:\tchange both\n^C:\texit\nelse:\tcontinue\n" + read -p " ns> " -n 1 input +## + if [[ $input == "v" ]] + then + unset VERB + $0 + elif [[ $input == "n" ]] + then + unset NOUN + $0 + elif [[ $input == "b" ]] + then + unset NOUN + unset VERB + $0 + else + $0 + fi +## -- cgit v1.2.3