doomemacs/modules/lang/crystal/config.el

35 lines
967 B
EmacsLisp
Raw Normal View History

;;; lang/crystal/config.el -*- lexical-binding: t; -*-
2015-08-27 23:25:35 -04:00
(after! crystal-mode
(set-formatter! 'crystal-mode '("crystal" "tool" "format" "-") :modes '(crystal-mode))
(set-lookup-handlers! 'crystal-mode
:definition #'crystal-def-jump
:references #'crystal-tool-imp)
(when (modulep! +lsp)
(add-hook 'crystal-mode-local-vars-hook #'lsp! 'append))
(map! :localleader
:map crystal-mode-map
:prefix "t"
"a" #'crystal-spec-all
"v" #'crystal-spec-buffer
"s" #'crystal-spec-line
"t" #'crystal-spec-switch))
2015-08-27 23:25:35 -04:00
(use-package! flycheck-crystal
:when (and (modulep! :checkers syntax)
(not (modulep! :checkers syntax +flymake)))
:after crystal-mode)
2018-02-06 02:04:58 -05:00
2019-10-19 14:54:31 -04:00
(use-package! flycheck-ameba
:when (and (modulep! :checkers syntax)
(not (modulep! :checkers syntax +flymake)))
2019-10-19 14:54:31 -04:00
:after crystal-mode
:config (flycheck-ameba-setup))
(use-package! inf-crystal
:commands crystal-switch-to-inf)