|
|
|
@ -11,13 +11,13 @@ case "$1" in
@@ -11,13 +11,13 @@ case "$1" in
|
|
|
|
|
-clear\t-Удалить все записи\n\ |
|
|
|
|
-h\t-Справка\n";; |
|
|
|
|
|
|
|
|
|
-e) vim $memfile;; |
|
|
|
|
-l) tail -"$2" $memfile | nl | \grep --color -E '.{1,}==>';; |
|
|
|
|
-s) grep "$2" $memfile | nl | \grep --color -E '.{1,}==>';; |
|
|
|
|
-remove) sed "$2d" -i $memfile;; |
|
|
|
|
-clear) > $memfile;; |
|
|
|
|
'') cat $memfile | nl | \grep --color -E '.{1,}==>';; |
|
|
|
|
-e) $EDITOR "$memfile";; |
|
|
|
|
-l) tail -"$2" "$memfile" | nl | \grep --color -E '.{1,}==>';; |
|
|
|
|
-s) grep "$2" "$memfile" | nl | \grep --color -E '.{1,}==>';; |
|
|
|
|
-remove) sed "$2d" -i "$memfile";; |
|
|
|
|
-clear) > "$memfile";; |
|
|
|
|
'') cat "$memfile" | nl | \grep --color -E '.{1,}==>';; |
|
|
|
|
*) printf "[ `\date '+%d.%m.%Y %H:%M:%S'` ] ==> $*\n" >> $memfile && printf \ |
|
|
|
|
"$greenЗаметка$yellow $* $greenуспешно добавлена\n$rstc" |
|
|
|
|
"${green}Заметка${yellow} $* ${green}успешно добавлена\n${rstc}" |
|
|
|
|
esac |
|
|
|
|
|
|
|
|
|