2014-03-11 20:10:50 +00:00
|
|
|
priority -50
|
|
|
|
|
2012-08-17 03:41:25 +00:00
|
|
|
###########################################################################
|
|
|
|
# SnipMate Snippets #
|
|
|
|
###########################################################################
|
|
|
|
snippet header
|
|
|
|
" File: ${1:`!v expand('%:t')`}
|
|
|
|
" Author: ${2:`!v g:snips_author`}
|
|
|
|
" Description: ${3}
|
|
|
|
${4:" Last Modified: `!v strftime("%B %d, %Y")`}
|
|
|
|
|
|
|
|
$0
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
snippet gvar "Global / configuration variable"
|
|
|
|
if !exists("g:${1:MyUltraImportantVar}")
|
|
|
|
let g:$1 = ${2:"${3:<tab>}"}
|
|
|
|
endif
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
snippet guard
|
|
|
|
if exists('${1:did_`!p snip.rv = snip.fn.replace('.','_')`}') || &cp${2: || version < 700}
|
|
|
|
finish
|
|
|
|
endif
|
|
|
|
let $1 = 1${3}
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
snippet f
|
|
|
|
fun ${1:function_name}(${2})
|
2014-03-11 20:10:50 +00:00
|
|
|
${3:" code}
|
2012-08-17 03:41:25 +00:00
|
|
|
endf
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
snippet for
|
2014-03-11 20:10:50 +00:00
|
|
|
for ${1:needle} in ${2:haystack}
|
|
|
|
${3:" code}
|
2012-08-17 03:41:25 +00:00
|
|
|
endfor
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
snippet wh
|
2014-03-11 20:10:50 +00:00
|
|
|
while ${1:condition}
|
|
|
|
${2:" code}
|
2012-08-17 03:41:25 +00:00
|
|
|
endw
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
snippet if
|
2014-03-11 20:10:50 +00:00
|
|
|
if ${1:condition}
|
|
|
|
${2:" code}
|
2012-08-17 03:41:25 +00:00
|
|
|
endif
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
snippet ife
|
2014-03-11 20:10:50 +00:00
|
|
|
if ${1:condition}
|
2012-08-17 03:41:25 +00:00
|
|
|
${2}
|
|
|
|
else
|
|
|
|
${3}
|
|
|
|
endif
|
|
|
|
endsnippet
|
|
|
|
|
|
|
|
# vim:ft=snippets:
|