From d735c9be3d92da2754336c37ff593a321fe50ae5 Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Thu, 12 Sep 2024 06:33:09 -0400 Subject: [PATCH] fix(graphviz): don't eagerly load flycheck at startup Due to eager expansion of the flycheck-define-checker macro. Causes a hefty delay in startup times. --- modules/lang/graphviz/config.el | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/lang/graphviz/config.el b/modules/lang/graphviz/config.el index 38e7c6fcc..f7710bc93 100644 --- a/modules/lang/graphviz/config.el +++ b/modules/lang/graphviz/config.el @@ -19,14 +19,14 @@ (when (and (modulep! :checker syntax) (not (modulep! :checker syntax +flymake))) (after! flycheck - (flycheck-define-checker graphviz-dot - "A checker using graphviz dot." - :command ("dot") - :standard-input t - :error-patterns ((error line-start "Error: : " (message "syntax error in line " line (* nonl))) - ;; I have no idea if this can actually be printed - (error line-start "Error: : " (message))) - :modes graphviz-dot-mode) + (eval '(flycheck-define-checker graphviz-dot + "A checker using graphviz dot." + :command ("dot") + :standard-input t + :error-patterns ((error line-start "Error: : " (message "syntax error in line " line (* nonl))) + ;; I have no idea if this can actually be printed + (error line-start "Error: : " (message))) + :modes graphviz-dot-mode)) (add-to-list 'flycheck-checkers 'graphviz-dot))) (map! :map graphviz-dot-mode-map