1
0
Fork 0
mirror of https://github.com/vim/vim synced 2025-03-29 04:56:43 +01:00
vim/runtime/indent/vim.vim

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

26 lines
786 B
VimL
Raw Normal View History

2022-09-27 17:30:34 +01:00
vim9script
2004-06-13 20:20:40 +00:00
2022-09-27 17:30:34 +01:00
# Vim indent file
# Language: Vim script
# Maintainer: The Vim Project <https://github.com/vim/vim>
# Last Change: 2024 Jul 12
# Former Maintainer: Bram Moolenaar <Bram@vim.org>
2004-06-13 20:20:40 +00:00
2022-09-27 17:30:34 +01:00
# Only load this indent file when no other was loaded.
if exists('b:did_indent')
finish
2004-06-13 20:20:40 +00:00
endif
2022-09-27 17:30:34 +01:00
b:did_indent = true
b:undo_indent = 'setlocal indentkeys< indentexpr<'
2019-11-02 14:09:23 +01:00
2022-09-27 17:30:34 +01:00
import autoload '../autoload/dist/vimindent.vim'
2019-11-02 14:09:23 +01:00
# export indentexpr as a global function, so it can be easily manipulated by plugins
g:VimIndent = vimindent.Expr
setlocal indentexpr=g:VimIndent()
2023-02-20 20:44:55 +00:00
setlocal indentkeys+==endif,=enddef,=endfu,=endfor,=endwh,=endtry,=endclass,=endinterface,=endenum,=},=else,=cat,=finall,=END,0\\
2022-09-27 17:30:34 +01:00
execute('setlocal indentkeys+=0=\"\\\ ,0=#\\\ ')
setlocal indentkeys-=0#
setlocal indentkeys-=: