You are not logged in.

#1 2007-09-11 02:11:51

vogt
Member
From: Toronto, Canada
Registered: 2006-11-25
Posts: 389

zsh completion gone wacky (for vim, my user, only) [solved]

using a config based on codemac's (http://dev.codemac.net/?p=config.git;a=summary) which is real good by the way.

the problem comes in the form of:

~/.zsh/ v v ali
_arguments:439: _vim_files: function definition file not found
_arguments:439: _vim_files: function definition file not found
_arguments:439: _vim_files: function definition file not found
_arguments:439: _vim_files: function definition file not found
_arguments:439: _vim_files: function definition file not found
_arguments:439: _vim_files: function definition file not found
_arguments:439: _vim_files: function definition file not found

the problem has nothing to do with the configuration, as the same .zshrc .zsh/* give perfect completion when run as root, or a new user (with the respective files copied to the new home dir/root)

permissions don't seem to be an issue; the 'test' user, just a member of users group (like me) works too.

and this is independent of compiling the config/functions as bytecode

eg whether the zshrc.zwc exists or not (by using the function:

# reload zshrc
function src()
{
        autoload -U zrecompile
                [ -f ~/.zshrc ] && zrecompile -p ~/.zshrc
                [ -f ~/.zcompdump ] && zrecompile -p ~/.zcompdump
                [ -f ~/.zcompdump ] && zrecompile -p ~/.zcompdump
                [ -f ~/.zshrc.zwc.old ] && rm -f ~/.zshrc.zwc.old
                [ -f ~/.zcompdump.zwc.old ] && rm -f ~/.zcompdump.zwc.old
                source ~/.zshrc
}

the only similar problem seems to have happened, and inexplicably solved/abandoned, here: http://www.mail-archive.com/debian-bugs … 33616.html

so, any ideas?

edit: solved:
  forgot about ~/.zcompdump, which obviously stores the completion, as being the source of the problem.
removing it (and the compiled version .zcompdump.zwc), and then having it regenerated from the actual config solved my problem it.

EDIT: clarify the .zcompdump.zwc business

Last edited by vogt (2008-01-27 22:33:47)

Offline

#2 2008-01-27 04:33:41

cwjiof
Member
From: Taichung, TW
Registered: 2008-01-27
Posts: 131

Re: zsh completion gone wacky (for vim, my user, only) [solved]

Unfortunately, I've encountered this kind of problem too, in my Z Shell, with the latest vim version of 7.1.228-1.

I removed ~/.zcompdump, but I don't know how to remove its bytecode version.
Anyone else knows? Thanks.

Last edited by cwjiof (2008-01-27 04:35:56)

Offline

#3 2008-01-27 16:04:23

cwjiof
Member
From: Taichung, TW
Registered: 2008-01-27
Posts: 131

Re: zsh completion gone wacky (for vim, my user, only) [solved]

I solved the problem too, but not using the method above.

$ echo  $fpath          (see the function PATH of zsh)
/usr/share/zsh/site-functions   /usr/share/zsh/4.3.4/functions
$ cd /usr/share/zsh/4.3.4/functions
$ ls  _vi*
_vim
$ sudo  cp _vim  _vim_files
$ vim  ~/.zsh<TAB>           (vim ~/.zshrc)
Then I got an error. The completion failed.
$ sudo  rm  /usr/share/zsh/4.3.4/functions/_vim_files
$ source  ~/.zshrc
$ exit
And when I logged in, the vim completion in zsh was OK.
But I don't know the reason. :-)

Last edited by cwjiof (2008-01-27 16:05:52)

Offline

#4 2008-01-27 23:22:46

codemac
Member
From: Cliche Tech Place
Registered: 2005-05-13
Posts: 794
Website

Re: zsh completion gone wacky (for vim, my user, only) [solved]

Just to give those of you using my configs for zsh, I keep them in mercurial.. The Git switch didn't last long.

Check out my sig for links.

Offline

#5 2010-08-18 18:49:09

bostonvaulter
Member
Registered: 2008-07-17
Posts: 36

Re: zsh completion gone wacky (for vim, my user, only) [solved]

Since I keep running into this problem on my computer, I wanted to add my solution on here. What seems to work for me is to remove both the ~/.zcompdump file and everything under ~/.zsh_cache/

Offline

#6 2010-08-19 18:49:34

Inxsible
Forum Fellow
From: Chicago
Registered: 2008-06-09
Posts: 9,183

Re: zsh completion gone wacky (for vim, my user, only) [solved]

And closing since there are more than a couple of solutions now....


Forum Rules

There's no such thing as a stupid question, but there sure are a lot of inquisitive idiots !

Offline

Board footer

Powered by FluxBB