[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/abzcoding/lvim/main/lua/user/diffview.lua [Back]  [Original]

local M = {}

M.config = function()
  local status_ok, diff = pcall(require, "diffview")
  if not status_ok then
    return
  end

  diff.setup {
    default_args = {
      DiffviewFileHistory = { "%" },
    },
    hooks = {
      diff_buf_read = function()
        vim.wo.wrap = false
        vim.wo.list = false
        vim.wo.colorcolumn = ""
      end,
    },
    enhanced_diff_hl = true,
    keymaps = {
      view = { q = "DiffviewClose" },
      file_panel = { q = "DiffviewClose" },
      file_history_panel = { q = "DiffviewClose" },
    },
  }
end

return M

Web Proxy Viewer  |  New URL  |  Original Page