Select Page

I use vim for almost all my editing needs, till now I often thought I should give using TextMate another try due to the nice Bundle that Masterzen made but there’s just something about desktop editing that puts me off.

I’ve also been renewing my efforts to better my VIM use and came across the excellent snipMate that enables you to do almost the same thing as textmate – the syntax for the snippets is even roughly the same.

I made a quick snippet file this morning for some common used bits that you can find here, see it in action below or view the movie better here:

Each time you see the input cursor jump between fields in the templates I’m simply pressing tab, shift-tab would cycle backward.

There are some nice things here you might not notice, for example editing a file test.pp and adding a class it will automatically fill in the class name as test.  Same for nodes, it’s really very powerful and the snippets are trivial to write.

I am using the vim syntax file that comes in the puppet tarball and the adaryn color scheme that ships with vim.