use consistent variable names with screen completion

This commit is contained in:
Guillaume Rousse 2009-12-30 00:43:31 +01:00
parent ec1e137977
commit 8c483668c1

View File

@ -3,7 +3,7 @@
have p4 &&
_p4()
{
local cur prev prev2 p4commands p4filetypes
local cur prev preprev p4commands p4filetypes
COMPREPLY=()
cur=`_get_cword`
@ -31,10 +31,10 @@ _p4()
;;
esac
elif [ $COMP_CWORD -gt 2 ]; then
prev2=${COMP_WORDS[COMP_CWORD-2]}
preprev=${COMP_WORDS[COMP_CWORD-2]}
case $prev in
-t)
case $prev2 in
case $preprev in
add|edit|reopen)
COMPREPLY=( $( compgen -W "$p4filetypes" -- "$cur") )
;;