mirror of
https://github.com/neovim/neovim.git
synced 2024-12-20 19:25:11 -07:00
a98a6996c2
Vim runtime files based on 7.4.384 / hg changeset 7090d7f160f7 Excluding: Amiga icons (*.info, icons/) doc/hangulin.txt tutor/ spell/ lang/ (only used for menu translations) macros/maze/, macros/hanoi/, macros/life/, macros/urm/ These were used to test vi compatibility. termcap "Demonstration of a termcap file (for the Amiga and Archimedes)" Helped-by: Rich Wareham <rjw57@cam.ac.uk> Helped-by: John <john.schmidt.h@gmail.com> Helped-by: Yann <yann@yann-salaun.com> Helped-by: Christophe Badoit <c.badoit@lesiteimmo.com> Helped-by: drasill <github@tof2k.com> Helped-by: Tae Sandoval Murgan <taecilla@gmail.com> Helped-by: Lowe Thiderman <lowe.thiderman@gmail.com>
46 lines
996 B
VimL
46 lines
996 B
VimL
" Vim indent file
|
|
" Language: gitolite configuration
|
|
" URL: https://github.com/tmatilai/gitolite.vim
|
|
" Maintainer: Teemu Matilainen <teemu.matilainen@iki.fi>
|
|
" Last Change: 2011-12-24
|
|
|
|
if exists("b:did_indent")
|
|
finish
|
|
endif
|
|
let b:did_indent = 1
|
|
|
|
setlocal autoindent
|
|
setlocal indentexpr=GetGitoliteIndent()
|
|
setlocal indentkeys=o,O,*<Return>,!^F,=repo,\",=
|
|
|
|
" Only define the function once.
|
|
if exists("*GetGitoliteIndent")
|
|
finish
|
|
endif
|
|
|
|
let s:cpo_save = &cpo
|
|
set cpo&vim
|
|
|
|
function! GetGitoliteIndent()
|
|
let prevln = prevnonblank(v:lnum-1)
|
|
let pline = getline(prevln)
|
|
let cline = getline(v:lnum)
|
|
|
|
if cline =~ '^\s*\(C\|R\|RW\|RW+\|RWC\|RW+C\|RWD\|RW+D\|RWCD\|RW+CD\|-\)[ \t=]'
|
|
return &sw
|
|
elseif cline =~ '^\s*config\s'
|
|
return &sw
|
|
elseif pline =~ '^\s*repo\s' && cline =~ '^\s*\(#.*\)\?$'
|
|
return &sw
|
|
elseif cline =~ '^\s*#'
|
|
return indent(prevln)
|
|
elseif cline =~ '^\s*$'
|
|
return -1
|
|
else
|
|
return 0
|
|
endif
|
|
endfunction
|
|
|
|
let &cpo = s:cpo_save
|
|
unlet s:cpo_save
|