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

Using CVS Completion Functions



Hi.  A few weeks ago I posted about trying to get a subset of cvs
completion for a script of mine.  This was the solution I came up with,
based on Peter's suggestion:

   _cvs_changed_files() {
     autoload +X _cvs
     _cvs_files_modified "$@" || _cvs_files "$@"
   }
   compdef _cvs_changed_files cvsvimdiff

This seemed to work for a while, but occasionally I get this error when
I try to complete:

   $ cvsvimdiff my_fi<TAB>_cvs_changed_files:2: command not found:
   _cvs_files_modified
   _cvs_changed_files:2: command not found: _cvs_files

Reading up on autoload, it seems that I should be autoloading not _cvs,
but _cvs_files_modified and _cvs_files.  This also worked occasionally,
but sometimes I get this error:

   $ cvsvimdiff my_fi<TAB>_cvs_changed_files:1: function definition
   file not found
   _cvs_changed_files:1: function definition file not found

Any idea why this might be?  fpath does contain the directory where _cvs
exists and all the cvs completion functions are defined.

Thanks!

-- 
Chris Johnson
cjohnson@xxxxxxxxxx
http://www.cs.utk.edu/~cjohnson



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