Hyprland-dotfiles/nvim/lua/modules/configs/editor/autoclose.lua

40 lines
1.1 KiB
Lua
Raw Permalink Normal View History

2024-07-21 02:51:17 -04:00
return function()
require("modules.utils").load_plugin("autoclose", {
keys = {
["("] = { escape = false, close = true, pair = "()" },
["["] = { escape = false, close = true, pair = "[]" },
["{"] = { escape = false, close = true, pair = "{}" },
["<"] = { escape = true, close = true, pair = "<>", enabled_filetypes = { "rust" } },
[">"] = { escape = true, close = false, pair = "<>" },
[")"] = { escape = true, close = false, pair = "()" },
["]"] = { escape = true, close = false, pair = "[]" },
["}"] = { escape = true, close = false, pair = "{}" },
['"'] = { escape = true, close = true, pair = '""' },
["`"] = { escape = true, close = true, pair = "``" },
["'"] = { escape = true, close = true, pair = "''", disabled_filetypes = { "rust" } },
},
options = {
disable_when_touch = false,
disabled_filetypes = {
"alpha",
"bigfile",
"checkhealth",
"dap-repl",
"diff",
"help",
"log",
"notify",
"NvimTree",
"Outline",
"qf",
"TelescopePrompt",
"toggleterm",
"undotree",
"vimwiki",
},
},
})
end