Merge pull request #718 from patrl/improve-dante
Refactored +dante feature
This commit is contained in:
commit
128af3f1e1
3 changed files with 7 additions and 19 deletions
|
@ -2,17 +2,8 @@
|
|||
;;;###if (featurep! +dante)
|
||||
|
||||
(def-package! dante
|
||||
:after haskell-mode
|
||||
:hook (haskell-mode . dante-mode)
|
||||
:hook haskell-mode
|
||||
:config
|
||||
(add-hook 'haskell-mode-hook #'interactive-haskell-mode))
|
||||
|
||||
|
||||
(def-package! company-ghc
|
||||
:when (featurep! :completion company)
|
||||
:after haskell-mode
|
||||
:init
|
||||
(add-hook 'haskell-mode-hook #'ghc-comp-init)
|
||||
:config
|
||||
(setq company-ghc-show-info 'oneline)
|
||||
(set-company-backend! 'haskell-mode #'company-ghc))
|
||||
(when (featurep! :feature syntax-checker)
|
||||
(add-hook! 'dante-mode-hook
|
||||
(flycheck-add-next-checker 'haskell-dante '(warning . haskell-hlint)))))
|
||||
|
|
|
@ -4,9 +4,8 @@
|
|||
(when (featurep! +dante)
|
||||
(unless (executable-find "cabal")
|
||||
(warn! "Couldn't find cabal, haskell-mode may have issues"))
|
||||
|
||||
(unless (executable-find "ghc-mod")
|
||||
(warn! "Couldn't find ghc-mod on PATH. Code completion will not work")))
|
||||
(unless (executable-find "hlint")
|
||||
(warn! "Couldn't find hlint. Flycheck may have issues in haskell-mode/")))
|
||||
|
||||
(when (featurep! +intero)
|
||||
(unless (executable-find "stack")
|
||||
|
|
|
@ -5,9 +5,7 @@
|
|||
|
||||
;;
|
||||
(cond ((featurep! +dante)
|
||||
(package! dante)
|
||||
(when (featurep! :completion company)
|
||||
(package! company-ghc)))
|
||||
(package! dante))
|
||||
(t
|
||||
(package! intero)
|
||||
(package! hindent)))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue