From 0e45f3229a67963c403f6f4b77106723845d35d8 Mon Sep 17 00:00:00 2001 From: Sanchayan Maity Date: Sat, 13 Jul 2024 20:03:35 +0530 Subject: [PATCH] nvim: autocmd: Open quickfix & localist list if populated This is required when using vimgrep without which we will have to invoke copen or lopen manually. --- nvim/.config/nvim/lua/autocmd.lua | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/nvim/.config/nvim/lua/autocmd.lua b/nvim/.config/nvim/lua/autocmd.lua index 3000894..431c39f 100644 --- a/nvim/.config/nvim/lua/autocmd.lua +++ b/nvim/.config/nvim/lua/autocmd.lua @@ -42,6 +42,18 @@ local aucmd_dict = { pattern = "*", command = "set guicursor=a:hor1-blinkon0" } + }, + QuickFixCmdPost = { + { + group = custom_augroup_id, + pattern = "[^l]*", + command = "cwindow" + }, + { + group = custom_augroup_id, + pattern = "l*", + command = "lwindow" + } } }