Debian Codegraph @

resources/_nheko

raw
1 #compdef nheko
2
3 function _nheko_select_profile() {
4 local -a profiles=(default)
5 while read -r line; do
6 [[ ${line} =~ '\\auth\\device_id' ]] && profiles+=(${line%%\\*})
7 done < ${XDG_CONFIG_HOME:-~/.config}/nheko/nheko.conf
8 _values "profile" ${profiles}
9 }
10
11 _arguments \
12 {'(--help)-h','(-h)--help'}'[Displays help on commandline options.]' \
13 --help-all'[Displays help including Qt specific options.]' \
14 {'(--version)-v','(-v)--version'}'[Displays version information.]' \
15 --debug'[Enables debug output.]' \
16 {'(--log-level)-l','(-l)--log-level'}'[Set the global log level, or a comma-separated list of <component>=<level> pairs, or both.]' \
17 {'(--log-type)-L','(-L)--log-type'}"[Set the log output type. A comma-separated list is allowed. The default is 'file,stderr'.]" \
18 {'(--profile)-p','(-p)--profile'}'[Create or select profile.]':'profile':'_nheko_select_profile'