Skip to content

Commit 72fbdef

Browse files
authored
update config for plugins (#472)
1 parent a14e86d commit 72fbdef

2 files changed

Lines changed: 31 additions & 1 deletion

File tree

lua/config/diffview.lua

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
local ok, diffview = pcall(require, "diffview")
2+
if not ok then
3+
return
4+
end
5+
6+
diffview.setup {
7+
enhanced_diff_hl = true,
8+
view = {
9+
default = {
10+
disable_diagnostics = true,
11+
},
12+
merge_tool = {
13+
layout = "diff3_mixed",
14+
},
15+
},
16+
file_history_panel = {
17+
win_config = {
18+
type = "split",
19+
position = "bottom",
20+
height = 10,
21+
},
22+
},
23+
}

lua/plugin_specs.lua

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,6 +408,9 @@ local plugin_specs = {
408408
{
409409
"sindrets/diffview.nvim",
410410
cmd = { "DiffviewOpen" },
411+
config = function()
412+
require("config.diffview")
413+
end,
411414
},
412415

413416
{
@@ -734,7 +737,11 @@ local plugin_specs = {
734737
event = "FileType qf",
735738
---@module "quicker"
736739
---@type quicker.SetupOptions
737-
opts = {},
740+
opts = {
741+
max_filename_width = function()
742+
return math.floor(math.min(40, vim.o.columns / 2))
743+
end,
744+
},
738745
},
739746
{
740747
"nickjvandyke/opencode.nvim",

0 commit comments

Comments
 (0)