mirror of https://github.com/nirenjan/dotfiles.git
Rename commands and add short forms
parent
5722777037
commit
92129f2357
29
scripts/note
29
scripts/note
|
@ -107,16 +107,17 @@ Usage: note <command> <arguments>
|
||||||
|
|
||||||
Commands
|
Commands
|
||||||
--------
|
--------
|
||||||
|
You can use the first letter of each command as a shortcut key.
|
||||||
|
|
||||||
Command Usage
|
Command Usage
|
||||||
------- -----
|
------- -----
|
||||||
new Follow this with the note name to create a new note
|
new Follow this with the note name to create a new note
|
||||||
edit Follow this with the note name to edit an existing note
|
edit Follow this with the note name to edit an existing note
|
||||||
|
show Follow this with the note name to display an existing note
|
||||||
delete Follow this with the note name to delete a note
|
delete Follow this with the note name to delete a note
|
||||||
list Prints the list of available notes
|
find Prints the list of available notes
|
||||||
history Displays the note history
|
log Displays the note history
|
||||||
find Finds all notes with the specified keyword in the filename
|
grep Finds all notes with the specified keyword in the text
|
||||||
search Finds all notes with the specified keyword in the text
|
|
||||||
init Run this the very first time to set up the folders
|
init Run this the very first time to set up the folders
|
||||||
help Prints this help message
|
help Prints this help message
|
||||||
version Prints the version information
|
version Prints the version information
|
||||||
|
@ -274,43 +275,43 @@ parse_args() {
|
||||||
note_arg="$*"
|
note_arg="$*"
|
||||||
|
|
||||||
case "$note_cmd" in
|
case "$note_cmd" in
|
||||||
"help")
|
"h" | "help")
|
||||||
help_cmd
|
help_cmd
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"new")
|
"n" | "new")
|
||||||
note_new
|
note_new
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"edit")
|
"e" | "edit")
|
||||||
note_edit
|
note_edit
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"show")
|
"s" | "show")
|
||||||
note_show
|
note_show
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"del" | "delete")
|
"d" | "delete")
|
||||||
note_delete
|
note_delete
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"hist"|"history")
|
"l" | "log")
|
||||||
note_history
|
note_history
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"init")
|
"i" | "init")
|
||||||
notes_init
|
notes_init
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"list" | "find")
|
"f" | "find")
|
||||||
note_list $1
|
note_list $1
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"search")
|
"g" | "grep")
|
||||||
note_search $1
|
note_search $1
|
||||||
;;
|
;;
|
||||||
|
|
||||||
"ver" | "version")
|
"v" | "version")
|
||||||
version_info
|
version_info
|
||||||
;;
|
;;
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue