aboutsummaryrefslogtreecommitdiffstats
path: root/SOURCE
diff options
context:
space:
mode:
authordanix <danix@danix.xyz>2023-04-26 16:02:40 +0200
committerdanix <danix@danix.xyz>2023-04-26 16:02:40 +0200
commit79f10f4efc3cc082749eb4154862bc3221e87e27 (patch)
tree3b190d55853c2dc2ff4138da7c37d9fd3a6a28a8 /SOURCE
parentda52e73a558956d6491c24ccec5f81a05dc1594e (diff)
downloadbash-notes-79f10f4efc3cc082749eb4154862bc3221e87e27.tar.gz
bash-notes-79f10f4efc3cc082749eb4154862bc3221e87e27.zip
fixed issue that prevented the script from reading input from command line.
Diffstat (limited to 'SOURCE')
-rw-r--r--SOURCE/main.sh6
1 files changed, 6 insertions, 0 deletions
diff --git a/SOURCE/main.sh b/SOURCE/main.sh
index 18bebdf..6198adb 100644
--- a/SOURCE/main.sh
+++ b/SOURCE/main.sh
@@ -27,26 +27,31 @@ while true; do
exit
;;
-a | --add )
+ TITLE=$2
shift 2
addnote "$TITLE"
exit
;;
-e | --edit )
+ NOTE=$2
shift 2
editnote "$NOTE"
exit
;;
-d | --delete )
+ NOTE=$2
shift 2
rmnote "$NOTE"
exit
;;
-s | --show )
+ NOTE=$2
shift 2
shownote "$NOTE"
exit
;;
-r | --restore )
+ RDIR=$2
shift 2
backup_restore $RDIR
exit
@@ -69,6 +74,7 @@ while true; do
exit
;;
--backup )
+ BDIR=$2
shift 2
backup_data $BDIR
exit