spell check markdown and tex files
This commit is contained in:
parent
6c34b63a2b
commit
15c11bb630
|
|
@ -18,3 +18,22 @@ autocmd({ "BufWritePre" }, {
|
||||||
pattern = "*",
|
pattern = "*",
|
||||||
command = [[%s/\s\+$//e]],
|
command = [[%s/\s\+$//e]],
|
||||||
})
|
})
|
||||||
|
|
||||||
|
-- Don"t auto commenting new lines
|
||||||
|
autocmd("BufEnter", {
|
||||||
|
pattern = "",
|
||||||
|
command = "set fo-=c fo-=r fo-=o"
|
||||||
|
})
|
||||||
|
|
||||||
|
-- spell check markdown and tex files
|
||||||
|
vim.cmd([[
|
||||||
|
augroup spellCheck
|
||||||
|
autocmd!
|
||||||
|
autocmd Filetype plaintext setlocal spell
|
||||||
|
autocmd FileType markdown setlocal spell
|
||||||
|
autocmd BufRead,BufNewFile *.md setlocal spell
|
||||||
|
autocmd BufRead,BufNewFile *.rmd setlocal spell
|
||||||
|
autocmd BufRead,BufNewFile *.Rmd setlocal spell
|
||||||
|
autocmd BufRead,BufNewFile *.tex setlocal spell
|
||||||
|
augroup END
|
||||||
|
]])
|
||||||
|
|
|
||||||
Reference in New Issue