ned: better option names

This commit is contained in:
PowerUser64 2022-01-30 17:19:00 -08:00
parent 3c4deabbcc
commit 39fa33465c

View file

@ -108,17 +108,17 @@ check_setup() {
} }
# Parse arguments (first character only) # Parse arguments (first character only)
case "${1:0:1}" in case "${1}" in
# help # help
'h') usage;; 'help') usage;;
# create and edit new note # create and edit new note
'n') new $@;; 'new') new $@;;
# edit an existing document or file # edit an existing document or file
'e') edit $@;; 'edit') edit $@;;
# run a shell (cd to) in the directory # run a shell (cd to) in the directory
'c'|'x'|'s') shell;; 'cd'|'shell') shell;;
# me: edit ned (the file you are looking at) # me: edit ned (the file you are looking at)
'm') $EDITOR "$(realpath "$0")";; 'me') $EDITOR "$(realpath "$0")";;
*) echo "no such option";; *) echo "no such option";;
esac esac