neovim: Fix formatoptions after ftplugins
This commit is contained in:
parent
62dc22ad70
commit
0caa9a44e1
1 changed files with 5 additions and 1 deletions
|
|
@ -28,10 +28,14 @@ vim.o.tabstop = 4
|
||||||
vim.o.softtabstop = 4
|
vim.o.softtabstop = 4
|
||||||
vim.o.shiftwidth = 4
|
vim.o.shiftwidth = 4
|
||||||
vim.o.smartindent = true
|
vim.o.smartindent = true
|
||||||
vim.opt.formatoptions = "crqnlj"
|
|
||||||
vim.o.foldenable = false
|
vim.o.foldenable = false
|
||||||
vim.o.joinspaces = false
|
vim.o.joinspaces = false
|
||||||
|
|
||||||
|
-- Some ftplugin files will add 'o' back in again, so remove it again after the
|
||||||
|
-- filetype has been determined.
|
||||||
|
vim.opt.formatoptions = "crqnlj"
|
||||||
|
vim.cmd([[ autocmd Filetype * setlocal formatoptions-=o ]])
|
||||||
|
|
||||||
vim.o.wrap = true
|
vim.o.wrap = true
|
||||||
vim.o.linebreak = true
|
vim.o.linebreak = true
|
||||||
vim.keymap.set("", "j", "gj", { silent = true })
|
vim.keymap.set("", "j", "gj", { silent = true })
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue