From 12c0a7441e6a18ee140b68cf8fc6d1c6468fd699 Mon Sep 17 00:00:00 2001 From: Luc Sinet Date: Mon, 26 Jul 2021 19:14:23 +0200 Subject: [Refactor] remove lv prefix (#1112) * Rename lv-utils into utils * Move commands defined in utils into core/commands.lua --- lua/core/commands.lua | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 lua/core/commands.lua (limited to 'lua/core/commands.lua') diff --git a/lua/core/commands.lua b/lua/core/commands.lua new file mode 100644 index 00000000..c42b385d --- /dev/null +++ b/lua/core/commands.lua @@ -0,0 +1,21 @@ +local M = {} + +M.defaults = { + [[ + function! QuickFixToggle() + if empty(filter(getwininfo(), 'v:val.quickfix')) + copen + else + cclose + endif + endfunction + ]], +} + +M.load = function(commands) + for _, command in ipairs(commands) do + vim.cmd(command) + end +end + +return M -- cgit v1.2.3