Skip to content

Instantly share code, notes, and snippets.

@dozed

dozed/eglot.el Secret

Created May 14, 2024 15:20
Show Gist options
  • Save dozed/9b70668200876179b2a5381c53683ca7 to your computer and use it in GitHub Desktop.
Save dozed/9b70668200876179b2a5381c53683ca7 to your computer and use it in GitHub Desktop.
(use-package haskell-mode
:ensure t
:bind (:map haskell-mode-map
("C-SPC" . 'company-complete)
("C-q" . 'eldoc-box-help-at-point)))
(use-package company
:ensure t
:hook haskell-mode
:init
(setq company-idle-delay nil)) ;; dont show company popup during typing
(use-package eglot
:ensure t
:config
(setq eldoc-display-functions (list 'eldoc-display-in-buffer)))
(use-package eldoc-box
:ensure t
:custom
(eldoc-box-clear-with-C-g t))
(use-package haskell-mode
:ensure t
:bind (:map haskell-mode-map
("C-SPC" . 'company-complete) ;; show company popup
("C-q" . 'lsp-ui-doc-show))) ;; show lsp-ui-doc
(use-package lsp-mode
:ensure t
:config
;; set highlight font
(set-face-attribute 'lsp-face-highlight-textual nil :weight 'bold :foreground nil :background nil))
(use-package lsp-ui
:ensure t
:init
(setq lsp-ui-doc-position 'at-point)
(setq lsp-ui-doc-show-with-mouse nil)
(setq lsp-ui-doc-use-webkit nil))
(use-package lsp-haskell
:ensure t)
(add-hook 'haskell-mode-hook #'lsp)
(use-package company
:ensure t
:hook haskell-mode
:init
(setq company-idle-delay nil)) ;; dont show company popup during typing
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment