From 7c52b2d4980166b883331367ef069fdf76e3c0f2 Mon Sep 17 00:00:00 2001 From: Adam <24621027+WhiteDopeOnPunk@users.noreply.github.com> Date: Thu, 4 Jan 2024 05:28:30 -0500 Subject: [PATCH] add some documentation --- configs/nvim/after/plugin/nvim_comment.lua | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/configs/nvim/after/plugin/nvim_comment.lua b/configs/nvim/after/plugin/nvim_comment.lua index c2b0008..2ca6833 100644 --- a/configs/nvim/after/plugin/nvim_comment.lua +++ b/configs/nvim/after/plugin/nvim_comment.lua @@ -1,3 +1,23 @@ +-- ## Usage +-- +-- Either use the command `CommentToggle`, e.g.: +-- +-- - `CommentToggle` comment/uncomment current line +-- - `67,69CommentToggle` comment/uncomment a range +-- - `'<,'>CommentToggle` comment/uncomment a visual selection +-- +-- Or use the default mappings: +-- +-- - `gcc` comment/uncomment current line, this does not take a count, if you want +-- a count use the `gc{count}{motion}` +-- - `gc{motion}` comment/uncomment selection defined by a motion (as lines are +-- commented, any comment toggling actions will default to a linewise): +-- - `gcip` comment/uncomment a paragraph +-- - `gc4w` comment/uncomment current line +-- - `gc4j` comment/uncomment 4 lines below the current line +-- - `dic` delete comment block +-- - `gcic` uncomment commented block + require('nvim_comment').setup( { -- Linters prefer comment and line to have a space in between markers