summaryrefslogtreecommitdiff
path: root/evil-flycheck.el
diff options
context:
space:
mode:
authorJames Nguyen <james@jojojames.com>2017-11-27 18:44:53 -0800
committerJames Nguyen <james@jojojames.com>2017-11-27 18:44:53 -0800
commitd87c72cf3b08bb08c077941c41c0fd9887d3f6e6 (patch)
treed608d7a64aff56eebaf2369728f54950b79232a3 /evil-flycheck.el
parent4d75512924205aa5ae7b53611cf32ca5939a57a9 (diff)
Flycheck: Use evil-define-key
Diffstat (limited to 'evil-flycheck.el')
-rw-r--r--evil-flycheck.el20
1 files changed, 13 insertions, 7 deletions
diff --git a/evil-flycheck.el b/evil-flycheck.el
index 8bc42a9..03e5655 100644
--- a/evil-flycheck.el
+++ b/evil-flycheck.el
@@ -34,13 +34,19 @@
(defun evil-flycheck-setup ()
"Set up `evil' bindings for `flycheck'."
- (evil-collection-util-evilify-map
- flycheck-error-list-mode-map
- :mode flycheck-error-list-mode
- :bindings
- "gr" 'flycheck-error-list-check-source
- "j" 'flycheck-error-list-next-error
- "k" 'flycheck-error-list-previous-error))
+ (evil-set-initial-state 'flycheck-error-list-mode 'normal)
+ (evil-define-key 'normal flycheck-error-list-mode-map
+ "gj" 'flycheck-error-list-next-error
+ "gk" 'flycheck-error-list-previous-error
+ (kbd "C-j") 'flycheck-error-list-next-error
+ (kbd "C-k") 'flycheck-error-list-previous-error
+ "]" 'flycheck-error-list-next-error
+ "[" 'flycheck-error-list-previous-error
+ "gr" #'flycheck-error-list-check-source
+ "s" #'flycheck-error-list-set-filter
+ "S" #'flycheck-error-list-reset-filter
+ "x" #'flycheck-error-list-explain-error
+ (kbd "<return>") #'flycheck-error-list-goto-error))
(provide 'evil-flycheck)
;;; evil-flycheck.el ends here