Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: cvs completion does not support partial path completion



Andrej Borsenkow wrote:

> Is "nice to have" in released version ...
> 
> bor@itsrm2% cvs diff S/M/t.c (meaning Src/Modules/termcap.c)
> No matches for: `cvs command', `file', `directory', or `removed file'

As far as I can see, the problem is in _cvs, which I always try to avoid
coming near to.  Have a look if you wish, you might have to have to deal
with interesting functions such as:

_cvs_modified_entries () {
  if _cvs_loadstat; then
    local expl match linedir realdir pat
    match=()
    : ${PREFIX:#(#b)(*/)(*)}
    linedir="$match[1]"
    realdir=${(e)~linedir}
    [[ -f "$realdir"CVS/Entries ]] &&
    [[ -n ${pat::="${(@j:|:)${(@)${(@)${(@)${(@)${(@)${(@M)${(@f)"$(<"$realdir"CVS/Entries)"}:#/*}#/}/\\/[^\\/]#\\///}%/[^/]#/[^/]#}:#${(j:|:)~${${${${(f)"$(LC_ALL=C builtin stat -gn +mtime -F '%a %b %e %T %Y' ${realdir}*(D) 2>/dev/null)"}##*/}/ //}//(#m)[][*?()<|^~#\\]/\\$MATCH}}}%%/*}//(#m)[][*?()<|^~#\\]/\\$MATCH}"} ]] &&
    _wanted files expl file _path_files -g "$pat"
  else
    _cvs_existing_entries
  fi
}

As far as I can see, that directory handling would require re-thinking
(or just placing a call to _files somewhere at the end as a catch-all
case when the clever functions failed, but placing it somewhere where it
won't get called more than once and not too early etc.).

Bye
  Sven


-- 
Sven Wischnowsky                         wischnow@xxxxxxxxxxxxxxxxxxxxxxx



Messages sorted by: Reverse Date, Date, Thread, Author