mirror of https://github.com/folke/lazy.nvim.git
fix(diff): make diffview work again. Fixes #304
This commit is contained in:
parent
62214df989
commit
e61b334cee
|
@ -23,11 +23,13 @@ M.handlers = {
|
|||
|
||||
---@type LazyDiffFun
|
||||
["diffview.nvim"] = function(plugin, diff)
|
||||
local args
|
||||
if diff.commit then
|
||||
vim.cmd.DiffviewOpen(("-C=%s"):format(plugin.dir) .. " " .. diff.commit)
|
||||
args = ("-C=%s"):format(plugin.dir) .. " " .. diff.commit
|
||||
else
|
||||
vim.cmd.DiffviewOpen(("-C=%s"):format(plugin.dir) .. " " .. diff.from .. ".." .. diff.to)
|
||||
args = ("-C=%s"):format(plugin.dir) .. " " .. diff.from .. ".." .. diff.to
|
||||
end
|
||||
vim.cmd("DiffviewOpen " .. args)
|
||||
end,
|
||||
|
||||
---@type LazyDiffFun
|
||||
|
|
Loading…
Reference in New Issue