Fix tabufline, auto ft=diff on diffview, add diff highlight syntax + lua tabstop=2
This commit is contained in:
parent
f445ce91e7
commit
2cc874f891
2
after/ftplugin/lua.vim
Normal file
2
after/ftplugin/lua.vim
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
setlocal tabstop=2
|
||||||
|
setlocal shiftwidth=2
|
||||||
11
after/syntax/diff.vim
Normal file
11
after/syntax/diff.vim
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
" hi DiffAdd gui=none guifg=NONE guibg=#bada9f
|
||||||
|
" hi DiffChange gui=none guifg=NONE guibg=#e5d5ac
|
||||||
|
" hi DiffDelete gui=bold guifg=#ff8080 guibg=#ffb0b0
|
||||||
|
" hi DiffText gui=none guifg=NONE guibg=#8cbee2
|
||||||
|
hi DiffAdd gui=none guifg=NONE guibg=#003200
|
||||||
|
hi DiffChange gui=none guifg=NONE guibg=#000032
|
||||||
|
hi DiffDelete gui=bold guifg=#ff8080 guibg=#602020
|
||||||
|
hi DiffText gui=bold guifg=NONE guibg=#102040
|
||||||
|
hi link @text.diff.add DiffAdd
|
||||||
|
hi link @text.diff.delete DiffDelete
|
||||||
|
hi link @text.diff.change DiffChange
|
||||||
@ -1 +1,11 @@
|
|||||||
return {}
|
return {
|
||||||
|
hooks = {
|
||||||
|
diff_buf_read = function(_)
|
||||||
|
vim.opt_local.wrap = false
|
||||||
|
vim.opt_local.list = false
|
||||||
|
end,
|
||||||
|
view_opened = function(_)
|
||||||
|
vim.api.nvim_command "set ft=diff"
|
||||||
|
end,
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|||||||
@ -206,11 +206,11 @@ map(
|
|||||||
-- Tabufline
|
-- Tabufline
|
||||||
-- cycle through buffers
|
-- cycle through buffers
|
||||||
map("n", "<tab>", function()
|
map("n", "<tab>", function()
|
||||||
require("nvchad.tabufline").tabuflineNext()
|
require("nvchad.tabufline").next()
|
||||||
end, { desc = "Goto next buffer" })
|
end, { desc = "Goto next buffer" })
|
||||||
|
|
||||||
map("n", "<S-tab>", function()
|
map("n", "<S-tab>", function()
|
||||||
require("nvchad.tabufline").tabuflinePrev()
|
require("nvchad.tabufline").prev()
|
||||||
end, { desc = "Goto prev buffer" })
|
end, { desc = "Goto prev buffer" })
|
||||||
|
|
||||||
-- close buffer + hide terminal buffer
|
-- close buffer + hide terminal buffer
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user