diff --git a/modules/lang/haskell/+intero.el b/modules/lang/haskell/+intero.el index 3ddbc5ef8..5dc501743 100644 --- a/modules/lang/haskell/+intero.el +++ b/modules/lang/haskell/+intero.el @@ -14,7 +14,3 @@ This is necessary because `intero-mode' doesn't do its own error checks." (add-hook 'haskell-mode-hook #'+haskell|init-intero) :config (set-lookup-handlers! 'intero-mode :definition #'intero-goto-definition)) - - -(def-package! hindent - :hook (haskell-mode . hindent-mode)) diff --git a/modules/lang/haskell/config.el b/modules/lang/haskell/config.el index 7da71bb97..9b44c7531 100644 --- a/modules/lang/haskell/config.el +++ b/modules/lang/haskell/config.el @@ -3,11 +3,13 @@ (cond ((featurep! +intero) (load! "+intero")) ((featurep! +dante) (load! "+dante"))) - ;; ;; Common plugins ;; +(def-package! hindent + :hook (haskell-mode . hindent-mode)) + (after! haskell-mode (set-repl-handler! 'haskell-mode #'switch-to-haskell) (add-to-list 'completion-ignored-extensions ".hi")) diff --git a/modules/lang/haskell/doctor.el b/modules/lang/haskell/doctor.el index b62d40aa1..91ac803ee 100644 --- a/modules/lang/haskell/doctor.el +++ b/modules/lang/haskell/doctor.el @@ -3,11 +3,14 @@ (when (featurep! +dante) (unless (executable-find "cabal") - (warn! "Couldn't find cabal, haskell-mode may have issues")) + (warn! "Couldn't find cabal, haskell-mode may have issues.")) (unless (executable-find "hlint") - (warn! "Couldn't find hlint. Flycheck may have issues in haskell-mode/"))) + (warn! "Couldn't find hlint. Flycheck may have issues in haskell-mode."))) (when (featurep! +intero) (unless (executable-find "stack") - (warn! "Couldn't find stack. Intero will not work"))) + (warn! "Couldn't find stack. Intero will not work."))) + +(unless (executable-find "hindent") + (warn! "Couldn't find hindent. hindent-mode won't work.")) diff --git a/modules/lang/haskell/packages.el b/modules/lang/haskell/packages.el index 541ed0bcd..f70614cb8 100644 --- a/modules/lang/haskell/packages.el +++ b/modules/lang/haskell/packages.el @@ -6,7 +6,7 @@ ;; (cond ((featurep! +dante) (package! dante)) - (t - (package! intero) - (package! hindent))) + (t (package! intero))) + +(package! hindent)