split nslookup completion

This commit is contained in:
Guillaume Rousse 2009-05-21 01:26:28 +02:00
parent 05eca6e6b9
commit f66e16c4f0
3 changed files with 20 additions and 15 deletions

View File

@ -4,6 +4,7 @@ sysconf_DATA = bash_completion
bashcompdir = $(sysconfdir)/bash_completion.d
bashcomp_DATA = contrib/ant \
contrib/apache2ctl \
contrib/bind-utils \
contrib/bitkeeper \
contrib/bittorrent \
contrib/bluez-utils \

View File

@ -3420,21 +3420,6 @@ _root_command()
}
complete -F _root_command $filenames sudo fakeroot really gksudo gksu kdesudo
have nslookup &&
_nslookup()
{
local cur
COMPREPLY=()
cur=${COMP_WORDS[COMP_CWORD]#-}
COMPREPLY=( $( compgen -P '-' -W 'all class= debug d2 domain= \
srchlist= defname search port= querytype= \
type= recurse retry root timeout vc \
ignoretc' -- $cur ) )
} &&
complete -F _nslookup nslookup
_longopt()
{
local cur prev

19
contrib/bind-utils Normal file
View File

@ -0,0 +1,19 @@
# -*- mode: shell-script; sh-basic-offset: 8; indent-tabs-mode: t -*-
# ex: ts=8 sw=8 noet filetype=sh
#
# bash completion for nslookup
have nslookup &&
_nslookup()
{
local cur
COMPREPLY=()
cur=${COMP_WORDS[COMP_CWORD]#-}
COMPREPLY=( $( compgen -P '-' -W 'all class= debug d2 domain= \
srchlist= defname search port= querytype= \
type= recurse retry root timeout vc \
ignoretc' -- $cur ) )
} &&
complete -F _nslookup nslookup