From: danix Date: Mon, 10 Apr 2023 08:21:09 +0000 (+0200) Subject: Added sleep 1 sec after deleting notes to allow the user to read the X-Git-Tag: v0.4~10 X-Git-Url: https://git.danix.xyz/?a=commitdiff_plain;h=f1343f207a71b79c69474bd0205fa09b46a6a876;p=bash-notes.git Added sleep 1 sec after deleting notes to allow the user to read the message before the window closes. modified: SOURCE/CORE/core-remove.sh modified: notes.sh --- diff --git a/SOURCE/CORE/core-remove.sh b/SOURCE/CORE/core-remove.sh index 5776bbc..0111d0f 100644 --- a/SOURCE/CORE/core-remove.sh +++ b/SOURCE/CORE/core-remove.sh @@ -29,6 +29,7 @@ function rmnote() { if [ ! "$OK" ]; then echo "invalid note \"$NOTE\"" echo "Use the note ID that you can fetch after listing your notes" + sleep 1 exit 1 fi @@ -43,8 +44,11 @@ function rmnote() { mv $TMPDB $DB rm $NOTESDIR/$FILE echo "Deleted note $TITLE" + sleep 1 + exit else echo "note not found" + sleep 1 exit 1 fi fi diff --git a/notes.sh b/notes.sh index 8a9c082..d0fd902 100755 --- a/notes.sh +++ b/notes.sh @@ -379,6 +379,7 @@ function rmnote() { if [ ! "$OK" ]; then echo "invalid note \"$NOTE\"" echo "Use the note ID that you can fetch after listing your notes" + sleep 1 exit 1 fi @@ -393,8 +394,11 @@ function rmnote() { mv $TMPDB $DB rm $NOTESDIR/$FILE echo "Deleted note $TITLE" + sleep 1 + exit else echo "note not found" + sleep 1 exit 1 fi fi