From 3d9b0b5278e343546ecc7a1d76b316876c6a4950 Mon Sep 17 00:00:00 2001 From: Sanchayan Maity Date: Fri, 22 Feb 2019 16:52:22 +0530 Subject: [PATCH] init.el: Add evil nerd commenter Signed-off-by: Sanchayan Maity --- init.el | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/init.el b/init.el index 8156c9f..875bce2 100644 --- a/init.el +++ b/init.el @@ -109,6 +109,8 @@ (setq-default evil-escape-key-sequence "jk") :config (evil-escape-mode 1)) +(use-package evil-nerd-commenter + :ensure t) ;; Anzu for search matching (use-package anzu @@ -306,7 +308,16 @@ "g/" '(helm-git-grep :which-key "open helm git grep") "g*" '(helm-git-grep-at-point - :which-key "open helm git grep at point"))) + :which-key "open helm git grep at point") + "ci" 'evilnc-comment-or-uncomment-lines + "cl" 'evilnc-quick-comment-or-uncomment-to-the-line + "ll" 'evilnc-quick-comment-or-uncomment-to-the-line + "cc" 'evilnc-copy-and-comment-lines + "cp" 'evilnc-comment-or-uncomment-paragraphs + "cr" 'comment-or-uncomment-region + "cv" 'evilnc-toggle-invert-comment-line-by-line + "." 'evilnc-copy-and-comment-operator + "\\" 'evilnc-comment-operator)) (general-define-key :states '(normal visual emacs)