summaryrefslogtreecommitdiffstats
path: root/Auxiliary
diff options
context:
space:
mode:
authorEisuke Kawashima <15070-e-kwsm@users.noreply.gitlab.kitware.com>2023-12-04 20:10:46 (GMT)
committerBrad King <brad.king@kitware.com>2023-12-11 15:07:33 (GMT)
commit27bfbbc2c0244dc64abcab48d96be70096f02ca7 (patch)
tree1091276a28e9b3c692be0633aa66bb8d761a1ab8 /Auxiliary
parenta6853135f569f0b040a34374a15a8361bb73901b (diff)
downloadCMake-27bfbbc2c0244dc64abcab48d96be70096f02ca7.zip
CMake-27bfbbc2c0244dc64abcab48d96be70096f02ca7.tar.gz
CMake-27bfbbc2c0244dc64abcab48d96be70096f02ca7.tar.bz2
vim: add undo_indent to match upstream vim indentation scripts
This resets `inde` (`indentexpr`) and `indk` (`indentkeys`) to the global values when closing. Upstream `vim` updated their indentation scripts in April 2022 to add this.
Diffstat (limited to 'Auxiliary')
-rw-r--r--Auxiliary/vim/indent/cmake.vim2
1 files changed, 2 insertions, 0 deletions
diff --git a/Auxiliary/vim/indent/cmake.vim b/Auxiliary/vim/indent/cmake.vim
index 0c662fa..28ecf84 100644
--- a/Auxiliary/vim/indent/cmake.vim
+++ b/Auxiliary/vim/indent/cmake.vim
@@ -17,6 +17,8 @@ let b:did_indent = 1
setlocal indentexpr=CMakeGetIndent(v:lnum)
setlocal indentkeys+==ENDIF(,ENDFOREACH(,ENDMACRO(,ELSE(,ELSEIF(,ENDWHILE(
+let b:undo_indent = "setl inde< indk<"
+
" Only define the function once.
if exists("*CMakeGetIndent")
finish