about summary refs log tree commit diff
path: root/emacs.d/wpc/packages/wpc-haskell.el
diff options
context:
space:
mode:
authorWilliam Carroll <wpcarro@gmail.com>2018-09-04T19·01-0400
committerWilliam Carroll <wpcarro@gmail.com>2018-09-04T19·01-0400
commit0244474e9fb6a49ec2d3d555e15e644f12479388 (patch)
tree118c3dfea9dbbb172eadf938a3c42d5019dd9d17 /emacs.d/wpc/packages/wpc-haskell.el
parent0d6c0881a81e2ba3a1cd88f8ae9dab6a86c966af (diff)
Debug startup, support LSP, update KBDs
Debug startup:
- some packages were missing explicit use-package calls, which made this
  configuration incompatible with fresh computers. After crashing my MBP
  and trying to get this working thereafter, I learned.

Support LSP:
- LSP support for Haskell is good; embrace and prefer over Intero

Update KBDs:
- preferences change
- changing to a light theme (for now)
Diffstat (limited to 'emacs.d/wpc/packages/wpc-haskell.el')
-rw-r--r--emacs.d/wpc/packages/wpc-haskell.el21
1 files changed, 9 insertions, 12 deletions
diff --git a/emacs.d/wpc/packages/wpc-haskell.el b/emacs.d/wpc/packages/wpc-haskell.el
index e6525537ba44..8e5dccfeaa9d 100644
--- a/emacs.d/wpc/packages/wpc-haskell.el
+++ b/emacs.d/wpc/packages/wpc-haskell.el
@@ -7,21 +7,10 @@
 ;;; Code:
 
 ;; Haskell support
-(use-package intero
-  :config
-  (intero-global-mode 1))
-
-;; text objects for Haskell
-(quelpa '(evil-text-objects-haskell
-          :fetcher github
-          :repo "urbint/evil-text-objects-haskell"))
-(require 'evil-text-objects-haskell)
 
+;; font-locking, glyph support, etc
 (use-package haskell-mode
-  :gfhook #'evil-text-objects-haskell/install
-  :after (intero evil-text-objects-haskell)
   :config
-  (flycheck-add-next-checker 'intero 'haskell-hlint)
   (let ((m-symbols
          '(("`mappend`" . "⊕")
            ("<>"        . "⊕"))))
@@ -29,7 +18,15 @@
   (setq haskell-font-lock-symbols t)
   (add-hook 'before-save-hook #'haskell-align-imports))
 
+;; LSP support
+(use-package lsp-haskell
+  :after (haskell-mode)
+  :config
+  (setq lsp-haskell-process-path-hie "hie-wrapper")
+  (add-hook 'haskell-mode-hook #'lsp-haskell-enable)
+  (add-hook 'haskell-mode-hook #'flycheck-mode))
 
+;; Test toggling
 (defun empire/haskell/module->test ()
   "Jump from a module to a test."
   (let ((filename (->> buffer-file-name