Improve gkrellm completion.
This commit is contained in:
parent
0b970c7477
commit
7c192589ae
1
CHANGES
1
CHANGES
@ -15,6 +15,7 @@ bash-completion (1.x)
|
|||||||
* Apply cardctl completion to pccardctl too.
|
* Apply cardctl completion to pccardctl too.
|
||||||
* Apply pine completion to alpine too.
|
* Apply pine completion to alpine too.
|
||||||
* Remove many unnecessary short option completions where long ones exist.
|
* Remove many unnecessary short option completions where long ones exist.
|
||||||
|
* Improve gkrellm completion.
|
||||||
|
|
||||||
-- David Paleino <d.paleino@gmail.com> Sun, 11 Oct 2009 11:11:57 +0200
|
-- David Paleino <d.paleino@gmail.com> Sun, 11 Oct 2009 11:11:57 +0200
|
||||||
|
|
||||||
|
@ -10,28 +10,37 @@ _gkrellm()
|
|||||||
prev=${COMP_WORDS[COMP_CWORD-1]}
|
prev=${COMP_WORDS[COMP_CWORD-1]}
|
||||||
|
|
||||||
case "$prev" in
|
case "$prev" in
|
||||||
-@(t|-theme))
|
-t|--theme)
|
||||||
_filedir -d
|
_filedir -d
|
||||||
return 0
|
return 0
|
||||||
;;
|
;;
|
||||||
-@(p|-plugin))
|
-p|--plugin)
|
||||||
_filedir 'so'
|
_filedir so
|
||||||
return 0
|
return 0
|
||||||
;;
|
;;
|
||||||
-@(s|-server))
|
-s|--server)
|
||||||
_known_hosts_real "$cur"
|
_known_hosts_real "$cur"
|
||||||
return 0
|
return 0
|
||||||
;;
|
;;
|
||||||
|
-l|--logfile)
|
||||||
|
_filedir
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
|
-g|--geometry|-c|--config|-P|--port|-d|--debug-level)
|
||||||
|
# Argument required but no completions available
|
||||||
|
return 0
|
||||||
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
if [[ "$cur" == -* ]]; then
|
if [[ "$cur" == -* ]]; then
|
||||||
COMPREPLY=( $( compgen -W '--help --theme --server \
|
COMPREPLY=( $( compgen -W '--theme --geometry --wm --m2 --nt \
|
||||||
--geometry --wm --withdrawn --config --nc \
|
--withdrawn --config --force-host-config --server --port --nc \
|
||||||
--force-host-config --demo --plugin --port' -- "$cur" ) )
|
--config-clean --nolock --plugin --demo --logfile --version \
|
||||||
|
--debug-level --help' -- "$cur" ) )
|
||||||
fi
|
fi
|
||||||
|
|
||||||
} &&
|
} &&
|
||||||
complete -F _gkrellm gkrellm gkrellm2
|
complete -F _gkrellm $filenames gkrellm gkrellm2
|
||||||
|
|
||||||
# Local variables:
|
# Local variables:
|
||||||
# mode: shell-script
|
# mode: shell-script
|
||||||
|
Loading…
x
Reference in New Issue
Block a user