You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
23 lines
336 B
VimL
23 lines
336 B
VimL
11 years ago
|
if exists('b:did_indent')
|
||
|
finish
|
||
|
endif
|
||
|
|
||
|
runtime! indent/coffee.vim
|
||
|
|
||
|
let b:did_indent = 1
|
||
|
|
||
|
setlocal indentexpr=GetLitCoffeeIndent()
|
||
|
|
||
|
if exists('*GetLitCoffeeIndent')
|
||
|
finish
|
||
|
endif
|
||
|
|
||
|
function GetLitCoffeeIndent()
|
||
|
if searchpair('^ \|\t', '', '$', 'bWnm') > 0
|
||
|
return GetCoffeeIndent(v:lnum)
|
||
|
else
|
||
|
return -1
|
||
|
endif
|
||
|
endfunc
|
||
|
|