#compdef rcommand

_rcommand() {

   if [[ $CURRENT == 2 ]]; then
      _hosts
    else

         if [[ CURRENT -ge 4 ]]; then
          compset -n 2
          _normal
        else
          local expl
        
          _wanted commands expl 'remote command' compadd "$@" -k commands
        fi

    fi
}


_rcommand "$@"