it's curious but bash-completion is with - and not _

This commit is contained in:
Filippo Valsorda 2012-12-08 00:37:26 +01:00
parent a9d2f7e894
commit 4c1d273e88
3 changed files with 4 additions and 4 deletions

View file

@ -0,0 +1,14 @@
__youtube-dl()
{
local cur prev opts
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
opts="{{flags}}"
if [[ ${cur} == * ]] ; then
COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
return 0
fi
}
complete -F __youtube-dl youtube-dl