parse -c and -s for list command
This commit is contained in:
19
sxbm
19
sxbm
@ -51,6 +51,23 @@ COMMANDS:
|
|||||||
-v|--version print the version and exit\n\n"
|
-v|--version print the version and exit\n\n"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bm_list(){
|
||||||
|
while [ -n "$1" ]; do
|
||||||
|
case "$1" in
|
||||||
|
"-c"|"--disable-colors")
|
||||||
|
COL_LINK=""; COL_TITLE=""; COL_LINE_NUM=""
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
"-s"|"--strict")
|
||||||
|
local TAG_STRICT="1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
break
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
############
|
############
|
||||||
### main ###
|
### main ###
|
||||||
@ -66,6 +83,8 @@ case "$1" in
|
|||||||
"add")
|
"add")
|
||||||
;;
|
;;
|
||||||
"ls"|"list")
|
"ls"|"list")
|
||||||
|
shift
|
||||||
|
bm_list "$@"
|
||||||
;;
|
;;
|
||||||
"open")
|
"open")
|
||||||
;;
|
;;
|
||||||
|
|||||||
Reference in New Issue
Block a user