Parse global cvs options from --help-options.

This commit is contained in:
Ville Skyttä 2009-10-20 20:58:27 +03:00
parent 881bd63774
commit 1233ebfecd

View File

@ -28,6 +28,11 @@ _cvs_commands()
cvs --help-commands 2>&1 | awk '/^( *|\t)/ { print $1 }' cvs --help-commands 2>&1 | awk '/^( *|\t)/ { print $1 }'
} }
_cvs_options()
{
cvs --help-options 2>&1 | awk '/^( *|\t)-/ { print $1 }'
}
_cvs() _cvs()
{ {
local cur count mode i cvsroot cvsroots pwd local cur count mode i cvsroot cvsroots pwd
@ -248,8 +253,7 @@ _cvs()
fi fi
;; ;;
"") "")
COMPREPLY=( $( compgen -W '$( _cvs_commands ) \ COMPREPLY=( $( compgen -W '$( _cvs_commands ) $( _cvs_options ) \
-Q -q -b -d -e -f -l -n -t -r -w -x -z \
--help --help-commands --help-options --version' -- "$cur" ) ) --help --help-commands --help-options --version' -- "$cur" ) )
;; ;;
*) *)