Questions tagged [snipmate]

Snipmate is a vim script that implements some of TextMate's snippets features in Vim.

Snipmate is a vim script that implements some of TextMate's snippets features in Vim. A snippet is a piece of often-typed text that you can insert into your document using a trigger word followed by a "Tab"

96 questions
1
vote
2 answers

vim and snipmate / snippets: how to create custom behavior

Here's my snippet: # Get repository of a table: snippet repo $$2 = $this->getRepository('${1:Bundle}:${2:TableName}') ${3} When I use it, here's what it may generate: $Person = $this->getRepository('MyBundle:Person') $Address =…
Olivier Pons
  • 15,363
  • 26
  • 117
  • 213
1
vote
1 answer

How can I enable SCSS snippets for Vim's SnipMate?

I have installed garbas’s snipMate fork and honza’s snippet repository for Vim 7.3. I’m running OS X Lion 10.7.5. I’m able to get everything working properly, as expected — my problem occurs when trying to add scss.snippets (I have tried to do so…
Sam
  • 11
  • 1
1
vote
1 answer

Modify snippet of snipmate without changing submodule

I installed the snipmate plugin and it works really well. I had to modify a snipped but that obviously resulted in a submodule change. Is there a better way to do this? Note: I'm using pathogen to manage plugins.
Dawg
  • 1,493
  • 2
  • 11
  • 9
1
vote
3 answers

snipMate only working on empty buffer?

I'm attempting to use snipMate with sql files, however it doesn't seem to work when editing an existing file. If I create a new empty buffer (no file; e.g. launch gvim from the start menu), and set the filetype to sql (:set ft=sql), it works. …
JesseBuesking
  • 6,496
  • 4
  • 44
  • 89
1
vote
2 answers

Is there a way to get a snippet to work immediately after a word?

Whenever I try to use a snippet (using snipMate) after a word, without a space, it does not work. So I have to hit space, type my snippet, hit tab, and then eliminate the space. Is there a better way of doing this? Is there a way to get the…
thequerist
  • 1,774
  • 3
  • 19
  • 27
1
vote
2 answers

snipMate: Insert file extension

I have a snipMate snippet that prints header comments for C and C++ files, and I would like it to print the full filename, as in "File: main.cpp". The documentation says: With no arguments, the default filename without an extension is returned;…
Toerndev
  • 715
  • 1
  • 6
  • 21
1
vote
1 answer

inserts spaces when using snipmate; works

I am using vim 7.3 on OSX Lion. I installed snipmate from garbas/vim-snipmate on github, and it appears that doesn't work in certain places while does. When I try to tab-complete an existing word in the file or if I want to tab-complete…
nathasm
  • 2,524
  • 5
  • 24
  • 35
0
votes
2 answers

Where to put my snippets on windows having vim with pathogen?

Like the subject, i found linux solution: https://stackoverflow.com/a/8103835 but on windows this apparently doesn't work. When added file "c:\Program Files\Vim\vimfiles\snippets\javascript.snippets", all js snippets didn't work.
xliiv
  • 5,399
  • 5
  • 29
  • 35
0
votes
2 answers

Vim: SnipMate + HAML

I've recently configured SnipMate to work alongside autocomplete for Rails development. I've bound both SnipMate and autocomplete to Tab, which works beautifully. However, when dealing with Haml files, Tab isn't behaving as expected. Instead of…
0
votes
1 answer

Vim snipMate tab jump

Vim snipMate doesn't work correctly finf[Tab] generate find(:first<+, :conditions => ['<+<+field+> = ?+>', <+true+>]+>) but cursor set to end of the line and dont jump by placeholders with [Tab] Update: I try it with html - all works fine, maybe…
Vyacheslav Loginov
  • 3,136
  • 5
  • 33
  • 49
0
votes
1 answer

vim - using snipmate and ragtag together

I am trying to switch to vim for all my editing and trying out the plugins. I have been using snipmate and ragtag and like them both. Now I am coding PHP with HTML in it and I saw this question to get snipmate to work with snippets for the two file…
ravl1084
  • 291
  • 4
  • 11
0
votes
2 answers

I want to do vim snipMate like TextMate

i use vim with snipMate But I find this problem if (true) {|}; in TextMate After pressing Enter key .. Look at the cursor if (true) { | }; in vim After pressing Enter key .. Look at the cursor if (true) { |}; How to Make vim , such as…
Tarek Saied
  • 6,482
  • 20
  • 67
  • 111
0
votes
1 answer

Adding folder of snippets to snipmate

snipmate comes with a ton of snippet files. This covers most of the bases. However I would like to add some snippet collections created by other users. When I download these the snippets are broken down into and placed in folders instead. I…
recursive_acronym
  • 2,981
  • 6
  • 40
  • 59
0
votes
1 answer

Is there any vim snippet plugin which is compatible with ideavim?

I use PyCharm using the Vim emulation feature IdeaVim. I have tried, without success, to integrate snipMate into PyCharm, which works like a Charm :P in the standard Vim. Does anybody known if there is a Vim snippet pluging which is compatible with…
Nisba
  • 3,210
  • 2
  • 27
  • 46
0
votes
2 answers

how to load a source at start in vimrc

I was not able to get snipMate to work with gvim and then found that there is an existing issue. the solution seems to be to run the following command after opening vim source ~/.vim/after/plugin/snipMate.vim To save me from the pain of…
Omnipresent
  • 29,434
  • 47
  • 142
  • 186