Remove auto trim whitespace

writing
Nick Zana 2 years ago
parent 040791ec40
commit 1e44af8740
No known key found for this signature in database
GPG Key ID: 936524EE913D6538

@ -1,16 +1,2 @@
-- Highlight on yank
vim.cmd('au TextYankPost * lua vim.highlight.on_yank {on_visual = false}' )-- disabled in visual mode
-- Trim Whitespace
vim.api.nvim_exec([[
fun! TrimWhitespace()
let l:save = winsaveview()
keeppatterns %s/\s\+$//e
call winrestview(l:save)
endfun
augroup AUTOCOMMANDGROUP
autocmd!
autocmd BufWritePre * :call TrimWhitespace()
autocmd BufEnter,BufWinEnter,TabEnter *.rs :lua require'lsp_extensions'.inlay_hints{}
augroup END
]], false)

Loading…
Cancel
Save