Scala Vim Snippets
I just took the Scala snippets from TextMate and put them in a snipMate .snippets file.
If you are in UNIX-land, you should be able to use
make install to install
If you are on Windows, copy the snippets file into your _vim\snippets folder. You'll know where this is better than I do.
make extract moves your scala.snippets file from your ~/.vim/snippets back to
the working directory so you can check them in.
The Makefile really might be the simplest thing you've ever seen.
It's quite possible when you are copying and pasting snippets files together to
bugger up the syntax. check.rb is a Ruby script that checks each line of the
script using the regex provided by the syntax file for snipMate snippets files.
make check will syntax check the file for you.
smDoc creates HTML and PDF documentation from snipMate files. HTML generation
is done using the smdoc.rb tool - invoked using
The point of smDoc is to produce printable PDFs - so you can print it out and carry it around with you as a cheatsheet/flashcard type thing.
The HTML documentation generation uses a simple JavaDoc-style syntax - for each snippet entry, you can prefix it with a line that starts "## ". In there, put as much description as you want to. You can use inline HTML if you like, but try to keep the descriptions short and snappy. It renders these into a definition list (the dl, dt, dd tags).
As well as this, you need to produce a small file called metadata.yml which contains the name of the programming language or tool you have written the snippets file for, the name of the primary author and a contact e-mail address. This is written in YAML.