Closed mands closed 8 years ago
That's interesting. I have pretty similar setup to yours (except I am on OS X). Are you sure you don't have any configs for Haskell development? Could you try M-: spacemacs-haskell//setup-completion-backend <ret>
while editing any hs
file. Does it turn on intero
? If not, could you please share the value of haskell-completion-backend
(SPC h d v haskell-completion-backend
)?
Thanks for replying.
So running M-: spacemacs-haskell//setup-completion-backend <ret>
returns the following backtrace:
Debugger entered--Lisp error: (void-variable spacemacs-haskell//setup-completion-backend)
eval(spacemacs-haskell//setup-completion-backend nil)
eval-expression(spacemacs-haskell//setup-completion-backend nil)
funcall-interactively(eval-expression spacemacs-haskell//setup-completion-backend nil)
call-interactively(eval-expression nil nil)
command-execute(eval-expression)
And SPC h d v haskell-completion-backend
returns this:
haskell-completion-backend is a variable defined in ‘config.el’.
Its value is ‘intero’
Documentation:
Completion backend used by company.
Available options are ‘ghci’, ‘intero’ and ‘ghc-mod’. Default is
‘ghci’.
Just to add - no, don't think I have any other configs around - it's a clean install of emacs (on Fedora 24) with a brand new .emacs.d
and .spacemacs
along with running stack setup
to make sure .stack
is setup correctly.
I guess @d12frosted meant M-: (spacemacs-haskell//setup-completion-backend)
, with parentheses.
Ah ok - M-: (spacemacs-haskell//setup-completion-backend)
from a .hs
file returns nil
and doesn't startup Intero.
@mands @TheBB oh yeah, I've meant with parentheses.
I think I know what's wrong with your setup. intero
works only when company
is used. So you have to enable auto-completion
layer.
I've sent a PR that should help to avoid such situations.
Also it's not stated in readme that you have to enable auto-completion
layer. So @mands thanks for bringing this issue up! 👍
Yep - adding the auto-completion
layer did the trick - intero then booted up immediately :) Thanks for the quick response/fix!
Fixed with released of Spacemacs v0.200. Let us know if you still have any problems with this issue.
Intero mode won't start for Stack-based Haskell project
Description :octocat:
I can't seem to get intero mode to load when opening a
stack
-based Haskell project. It always startscompany-ghci
instead even though I've configuredintero
within.spacemacs
.Intero starts normally within the same project using vanilla emacs. I can also manually start Intero within spacemacs per buffer with
M-x intero-mode
however this doesn't enable the key-bindings (e.g.SPC m i
is not defined). Perhaps unrelated, but layer will force-install Intero version0.1.15
, even thoughstack
wants to install0.1.16
.Have updated all packages but no luck.
Other system info
Stack version -
Version 1.1.2, Git revision cebe10e845fed4420b6224d97dcabf20477bbd4b (3646 commits) x86_64 hpack-0.14.0
GHC -7.10.3
fromlts-6.7
(installed via Stack, no system ghc present) Intero -0.1.15
Shell - fishReproduction guide :beetle:
.hs
file within a Stack projectObserved behaviour: :eyes: :broken_heart:
Expected behaviour: :heart: :smile:
System Info :computer:
Backtrace :paw_prints: