Slippery Snippets
Monday, September 11, 2006
  Calling Sven I got an email from Sven the other day but my mail bounced. I don't think his domain likes gmail.

In case he's reading this here's the reply that got rejected:


> Are there plugins known not to work with snippetsemu? According to :map none
> of my plugins map Tab, except for minibufexplorer, which maps and
> .


The only one I've heard of is the emacs emulation plugin. Make sure
you're using a version greater than 0.5.4 and that you've set
g:snip_set_textmate_cp = 1 in your vimrc with:

let g:snip_set_textmate_cp = 1

If you're still having trouble once you've restarted vim then drop me
a mail along with which version of the script you're using, what
version of Vim, what flavour of Linux and what other plugins you've
got and I'll have a go at bug hunting for you.
 
Comments:
Hi Sven,

The problem with the cursor being put at the start is usually due to a mismatch between the tags used and the tags defined.

I've got the plugin working fine on Ubuntu and Debian with Vim 7.

If you're brave enough to look into the source code then check out the Jumper function first as this is called when Tab is hit. I may sprinkle some debugging statements through the code at some point.
 
Hi Sven,

Just to double check try doing the following:

Start Vim as normal.

Type

:let g:snip_start_tag = '<'
:let g:snip_end_tag = '>'
:Iabbr test this is a test<>

and then type 'test' in insert mode and hit tab. This way we're sure that the tags being used are correct.

Otherwise type:

:let g:snip_start_tag
:let g:snip_end_tag

as this will let you see what the variables are currently set to.
 
Hi Sven,

No problem. If nothing else it's highlighted the lack of good defaults and debugging in the current version. This is something I will be addressing in an upcoming version.
 
Post a Comment

Subscribe to Post Comments [Atom]





<< Home

Archives
July 2006 / August 2006 / September 2006 / October 2006 / November 2006 / December 2006 / March 2007 / April 2007 / May 2007 / July 2007 / September 2007 / February 2008 / June 2009 / December 2010 /


Powered by Blogger

Subscribe to
Posts [Atom]