aboutsummaryrefslogtreecommitdiff
path: root/debian/git-buildpackage.bash-completion
blob: 9e3023e04a99685d317dcad85544dce66d4033c0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# -*- shell-script -*-
#
# Bash tab auto-completion rules for git-buildpackage.
# Put this file in /etc/bash_completion.d/ and bash will automatically load it.
#
# By Siegfried-Angel Gevatter Pujals <siegfried@gevatter.com>

have git-buildpackage &&
_git_buildpackage()
{
    local options=$(git-buildpackage --help | egrep -o '^ +\-\-[a-z\-]+=?')
    local cur=${COMP_WORDS[COMP_CWORD]}
	COMPREPLY=($(compgen -W "$options" -- $cur))
}
[ "${have:-}" ] && complete -F _git_buildpackage -o default git-buildpackage