neovim

Neovim text editor
git clone https://git.dasho.dev/neovim.git
Log | Files | Refs | README

tera.vim (1162B)


      1 " Vim filetype plugin file
      2 " Language:             Tera
      3 " Maintainer:           Muntasir Mahmud <muntasir.joypurhat@gmail.com>
      4 " Last Change:          2025 Mar 08
      5 " 2025 Apr 16 by Vim Project (set 'cpoptions' for line continuation, #17121)
      6 
      7 if exists("b:did_ftplugin")
      8  finish
      9 endif
     10 let b:did_ftplugin = 1
     11 
     12 let s:cpo_save = &cpo
     13 set cpo&vim
     14 
     15 setlocal autoindent
     16 
     17 setlocal commentstring={#\ %s\ #}
     18 setlocal comments=s:{#,e:#}
     19 
     20 if exists("loaded_matchit")
     21  let b:match_ignorecase = 0
     22  let b:match_words = '{#:##\|#},{% *if:{% *else\>:{% *elif\>:{% *endif %},{% *for\>:{% *endfor %},{% *macro\>:{% *endmacro %},{% *block\>:{% *endblock %},{% *filter\>:{% *endfilter %},{% *set\>:{% *endset %},{% *raw\>:{% *endraw %},{% *with\>:{% *endwith %}'
     23 endif
     24 
     25 setlocal includeexpr=substitute(v:fname,'\\([^.]*\\)$','\\1','g')
     26 setlocal suffixesadd=.tera
     27 
     28 setlocal expandtab
     29 setlocal shiftwidth=2
     30 setlocal softtabstop=2
     31 
     32 let b:undo_ftplugin = "setlocal autoindent< commentstring< comments< " ..
     33      \ "includeexpr< suffixesadd< expandtab< shiftwidth< softtabstop<"
     34 let b:undo_ftplugin .= "|unlet! b:match_ignorecase b:match_words"
     35 
     36 let &cpo = s:cpo_save
     37 unlet s:cpo_save