From: Tim Hammerquist Date: 2005-11-20T18:02:27+09:00 Subject: Re: matchit.vim (was: why is my array a hash?) Wybo Dekker wrote: > Tim Hammerquist wrote: > > It looks like either matchit.vim is not being loaded (is it > > in your ~/.vim/plugin/ directory?) or ftplugin/ruby.vim > > isn't being loaded. > > It *is* loaded - I tested that by introducing an error (iif > instead of if) in the matchit.vim file, and that was detected: > > Error detected while processing /home/wybo/.vim/plugin/matchit.vim: > line 40: > E492: Not an editor command: iif exists("loaded_matchit") || &cp > Hit ENTER or type command to continue > > In my ~/.vim I have: > > /doc: > total 24 > -rw-r--r-- 1 wybo users 18998 20040512 16:28:33 matchit.txt > -rw-r--r-- 1 wybo users 1961 20051119 13:29:28 tags > > /plugin: > total 32 > -rw-r--r-- 1 wybo users 30374 20040515 17:10:28 matchit.vim > > /syntax: > total 8 > -rw-r--r-- 1 wybo users 1119 20050705 06:58:57 eruby.vim > -rw-r--r-- 1 wybo users 4081 20051119 13:26:41 ruby.vim > > Is that correct? Yup. However, Item 6 in ftplugin/ruby.vim maybe be misleading. matchit.vim doesn't set the b:match_words variable. This is done by the language-specific ftplugins (the ones that support matchit, anyway). Thus, echo'ing the b:match_world var will only work from inside the buffer of a ruby file. Apologies if this is a stupid question, but... with the setup you describe above, and with the active buffer being a correctly identified ruby file, does the `:echo b:match_words` test work? If you still have trouble, try asking on the vim-ruby-devel ML, found at . HTH, Tim Hammerquist