From 4aa283119ac8abe8e8c4932c3f5ceb026052eebd Mon Sep 17 00:00:00 2001 From: georgejean Date: Fri, 23 Jun 2023 01:29:57 +0200 Subject: [PATCH] Fix too long descriptions for Comment.nvim's key mapping and add g key to trigger which-key (#2145) --- lua/plugins/init.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lua/plugins/init.lua b/lua/plugins/init.lua index 8d855f1..16a9ca1 100644 --- a/lua/plugins/init.lua +++ b/lua/plugins/init.lua @@ -201,10 +201,10 @@ local default_plugins = { { "numToStr/Comment.nvim", keys = { - { "gcc", mode = "n" , desc = "Toggles the current line using linewise comment"}, - { "gc", mode = {"n","o","x"} , desc = "Toggles the region using linewise comment"}, - { "gbc", mode = "n" , desc = "Toggles the current line using blockwise comment"}, - { "gb", mode = {"n","o","x"} , desc = "Toggles the region using blockwise comment"}, + { "gcc", mode = "n", desc = "Toggles comment on current line" }, + { "gc", mode = { "n", "o", "x" }, desc = "Toggles comment on current line's region" }, + { "gbc", mode = "n", desc = "Toggles blockwise comment on current line" }, + { "gb", mode = { "n", "o", "x" }, desc = "Toggles blockwise comment on region" }, }, init = function() require("core.utils").load_mappings "comment" @@ -256,7 +256,7 @@ local default_plugins = { -- Only load whichkey after all the gui { "folke/which-key.nvim", - keys = { "", '"', "'", "`", "c", "v" }, + keys = { "", '"', "'", "`", "c", "v", "g" }, init = function() require("core.utils").load_mappings "whichkey" end,