Skip to content

Commit d5ae1f7

Browse files
committed
changes for README from SirVers 32650 (last commit of last PR)
1 parent 26ff066 commit d5ae1f7

File tree

1 file changed

+43
-66
lines changed

1 file changed

+43
-66
lines changed

Diff for: README.md

+43-66
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
IMPORTANT: comment on: [What about merging with Ultisnip using its engine](https://github.com/garbas/vim-snipmate/issues/114)
2-
31
Snipmate & UltiSnip Snippets
42
============================
53

@@ -9,51 +7,48 @@ It is community-maintained and many people have contributed snippet files and
97
other improvements already.
108

119
Contents
12-
========
10+
--------
1311

14-
snippets/*: snippets using snipmate format
15-
UltiSnips/*: snippets using UltiSnips format
12+
- `snippets/*`: snippets using snipmate format
13+
- `UltiSnips/*`: snippets using UltiSnips format
1614

1715
Snippet engines supporting vim-snippets
18-
========================================
16+
----------------------------------------
1917

2018
There are different forks of snippet engines which allow the user to insert
2119
snippets by typing the name of a snippet hitting the expansion mapping.
2220

23-
github.com/garbas/vim-snipmate:
24-
VimL, snipmate-snippets, engine sometimes behaves strange, supports
25-
rewriting snippets on the fly (eg adding a second version with folding
26-
markers)
27-
28-
github.com/MarcWeber/UltiSnips:
29-
python, snipmate-snippets and UltiSnips-snippets
30-
31-
github.com/SirVer/ultisnips:
32-
python, UltiSnips-snippets
33-
34-
github.com/Shougo/neosnippet:
35-
viml, has a compatible mode allowing to reuse most snipmate snippets ?
36-
37-
github.com/drmingdrmer/xptemplate:
38-
Totally different syntax, does not read snippets contained in this file,
39-
but it is also very powerful. It does not support vim-snippets (just
40-
listing it here for completness)
41-
42-
This tries to be a more comprehensive list (which still is incomplete)
43-
http://vim-wiki.mawercer.de/wiki/topic/text-snippets-skeletons-templates.html
44-
45-
UltiSnips engine has additional features such as "nested snippets".
46-
47-
Which one to use? If you have python give MarcWeber/UltiSnips a try because its
48-
fast and supports all important features. You can prefer the UltiSnip versions
49-
of the snippets by setting the "always_use_first_snippet" option to 1.
21+
- [github.com/SirVer/ultisnips](https://github.com/SirVer/ultisnips):
22+
python, supports all snippets in this repo.
23+
- [github.com/garbas/vim-snipmate](https://github.com/garbas/vim-snipmate):
24+
VimL, snipmate-snippets, engine sometimes behaves strange. Supports
25+
snippets/*
26+
- [github.com/Shougo/neosnippet](https://github.com/Shougo/neosnippet.vim):
27+
VimL, supports snippets/* with some configuration.
28+
- [github.com/drmingdrmer/xptemplate](https://github.com/drmingdrmer/xptemplate):
29+
Totally different syntax, does not read snippets contained in this file, but
30+
it is also very powerful. It does not support vim-snippets (just listing it
31+
here for completness)
32+
33+
There tries to be a more comprehensive list (which still is incomplete) here:
34+
http://vim-wiki.mawercer.de/wiki/topic/text-snippets-skeletons-templates.html
35+
36+
UltiSnips has additional features such as high speed, nesting snippets,
37+
expanding snippets in snippets and offers powerful transformations on text in
38+
snippets (like visual selections or placeholder texts).
39+
40+
Which one to use? If you have python give
41+
[SirVer/ultisnips](https://github.com/SirVer/ultisnips) a try because its fast
42+
and has the most features.
5043

5144
If you have VimL only (vim without python support) your best option is using
52-
garbas/vim-snipmate and cope with the minor bugs found in the engine.
45+
[garbas/vim-snipmate](https://github.com/garbas/vim-snipmate) and cope with the
46+
minor bugs found in the engine.
5347

5448

5549
Installation
56-
============
50+
------------
51+
5752
First be aware that there are many options, see "Snippet engines" above.
5853
Second be aware than there are [tons of plugin managers](http://vim-wiki.mawercer.de/wiki/topic/vim%20plugin%20managment.html)
5954
which is why Marc Weber thinks that it doesn't make sense to repeat the same
@@ -84,7 +79,8 @@ If you still have trouble getting this to work create a github ticket, ask on
8479
irc or the mailinglist.
8580

8681
Policies / for contributors
87-
===========================
82+
---------------------------
83+
8884
Some snippets are useful for almost all languages, so let's try to have the same
8985
triggers for them:
9086

@@ -96,11 +92,7 @@ el : else ..
9692
wh : while (cond) ...
9793
```
9894

99-
If you're not satisfied with these defaults, open a ticket that we implement
100-
aliasing. Then you can remap "else" to "el" or the like.
101-
102-
103-
Don't add stupid placeholder default texts like
95+
Don't add useless placeholder default texts like
10496
```
10597
if (${1:condition}){
10698
${2:some code here}
@@ -127,7 +119,7 @@ Discuss at: https://github.com/honza/vim-snippets/issues/230
127119

128120

129121
Related repositories
130-
====================
122+
--------------------
131123
We also encourage people to maintain sets of snippets for particular use cases
132124
so that all users can benefit from them. People can list their snippet repositories here:
133125

@@ -138,15 +130,15 @@ so that all users can benefit from them. People can list their snippet reposito
138130

139131
Installation using VAM: "github:rbonvall/snipmate-snippets-bib"
140132

141-
142133
Future - ideas - examples
143-
=========================
134+
-------------------------
135+
144136
[overview snippet engines](http://vim-wiki.mawercer.de/wiki/topic/text-snippets-skeletons-templates.html)
145137
If you have ideas you can add them to that list of "snippet engine features by example".
146138

147139

148140
Historical notes
149-
================
141+
----------------
150142

151143
[vim-snipmate][1] was originally started by [Michael Sanders][2] who has now
152144
unfortunately abandoned the project. [Rok Garbas][3] is now maintaining a
@@ -170,14 +162,6 @@ let g:snipMate.scope_aliases = {}
170162
let g:snipMate.scope_aliases['ruby'] = 'ruby,ruby-rails,ruby-1.9'
171163
```
172164

173-
or github.com/MarcWeber/UltiSnips this way:
174-
175-
176-
```vim
177-
let g:UltiSnips = {}
178-
179-
let g:UltiSnips.snipmate_ft_filter = {
180-
\ 'default' : {'filetypes': ["FILETYPE"] },
181165
\ 'ruby' : {'filetypes': ["ruby", "ruby-rails", "ruby-1.9"] },
182166
```
183167
@@ -192,16 +176,15 @@ ruby-library-version triplet. Sometimes postfixing a name such as
192176
193177
will do it then if syntax has changed.
194178
179+
195180
Language maintainers
196181
--------------------
197182
198183
No one can really be proficient in all programming languages. If you would like
199184
to maintain snippets for a language, please get in touch.
200185
201-
Notes: People are interested in snippets - and their interest may stop again
202-
at will. So its ok if people maintain a language only for a short period of
203-
time - or jump in and get things done - don't let the flow stop :)
204-
vim-snippets is not like the "linux kernel".
186+
Notes: People are interested in snippets - and their interest may wane again.
187+
This list is kept up-to-date on a best effort basis.
205188
206189
* Python - [honza](http://github.com/honza)
207190
* Javascript - [honza](http://github.com/honza)
@@ -220,18 +203,13 @@ Until further work is done on `vim-snipmate`, please don't add folding markers
220203
into snippets. `vim-snipmate` has some comments about how to patch all snippets
221204
on the fly adding those.
222205
223-
Because MarcWeber/UltiSnips [6] supports also snipmate-snippets there is no
224-
need to duplicate all snippets - only those snippets who use advanced UltiSnips
225-
features should be duplicated in UltiSnips (?)
206+
Because UltiSnips reads snipmate-snippets too there is no need to duplicate all
207+
snippets - only those snippets who use advanced UltiSnips features should be
208+
duplicated in UltiSnips.
226209
227210
Currently all snippets from UltiSnips have been put into UltiSnips - some work
228211
on merging should be done (dropping duplicates etc)
229212
230-
Authors
231-
-------
232-
233-
For a list of authors, please see the `AUTHORS` files.
234-
235213
License
236214
-------
237215
@@ -243,5 +221,4 @@ terms of the MIT license.
243221
[2]: http://github.com/msanders
244222
[3]: http://github.com/garbas
245223
[4]: http://github.com/garbas/vim-snipmate
246-
[6]: http://github.com/MarcWeber/UltiSnips
247224
[7]: http://github.com/SirVer/ultisnips

0 commit comments

Comments
 (0)