Ville Skyttä fc0c76
# -*- mode: shell-script; sh-basic-offset: 8; indent-tabs-mode: t -*-
Ville Skyttä fc0c76
# ex: ts=8 sw=8 noet filetype=sh
Ville Skyttä fc0c76
#
Ville Skyttä fc0c76
# bash completion for repomanage
Ville Skyttä 192263
Ville Skyttä fc0c76
have repomanage &&
Ville Skyttä 192263
_repomanage()
Ville Skyttä 192263
{
Ville Skyttä fc0c76
	local cur prev
Ville Skyttä 192263
Ville Skyttä fc0c76
	COMPREPLY=()
Ville Skyttä fc0c76
	cur=`_get_cword`
Ville Skyttä fc0c76
	prev=${COMP_WORDS[COMP_CWORD-1]}
Ville Skyttä 192263
Ville Skyttä fc0c76
	[[ "$prev" == -@(h|-help|k|-keep) ]] && return 0
Ville Skyttä 192263
Ville Skyttä fc0c76
	if [[ "$cur" == -* ]] ; then
Ville Skyttä fc0c76
		COMPREPLY=( $( compgen -W '-o --old -n --new -s --space -k \
Ville Skyttä fc0c76
				--keep -c --nocheck -h --help' -- $cur ) )
Ville Skyttä fc0c76
	else
Ville Skyttä fc0c76
		_filedir -d
Ville Skyttä fc0c76
	fi
Ville Skyttä fc0c76
} &&
Ville Skyttä fc0c76
complete -F _repomanage $filenames repomanage