Skip to content

Commit

Permalink
haskell layer: fix haskell-snippets loading
Browse files Browse the repository at this point in the history
  • Loading branch information
syl20bnr authored and kryptt committed Sep 6, 2015
1 parent 76f8db2 commit db556bc
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions contrib/lang/haskell/packages.el
Original file line number Diff line number Diff line change
Expand Up @@ -183,8 +183,17 @@
(add-hook 'evil-emacs-state-exit-hook 'spacemacs//haskell-indentation-hide-guides))))

(defun haskell/init-haskell-snippets ()
(use-package haskell-snippets
:defer t))
;; manually load the package since the current implementation is not lazy
;; loading friendly (funny coming from the haskell mode :-))
(setq haskell-snippets-dir (spacemacs//get-package-directory
'haskell-snippets))

(defun haskell-snippets-initialize ()
(let ((snip-dir (expand-file-name "snippets" haskell-snippets-dir)))
(add-to-list 'yas-snippet-dirs snip-dir t)
(yas-load-directory snip-dir)))

(eval-after-load 'yasnippet '(haskell-snippets-initialize)))

(defun haskell/init-hindent ()
(use-package hindent
Expand Down

0 comments on commit db556bc

Please sign in to comment.