Closed lukexi closed 8 years ago
I believe this has the same root cause as https://github.com/commercialhaskell/stack/issues/347
While this isn't mentioned there, one thing to try might be to add an other-modules
list for the executable. Not sure if that'll fix it, but cabal does support this field for executables / test-suites, though it doesn't demand it.
I have the same issue when writing tests (really sucks for TDD). I'm on emacs and stack-mode properly load my tests module either when I run stack-load-buffer
.
Since https://github.com/commercialhaskell/stack/pull/753 I've been able to run stack ghci <packagename>:exec:<executable compenent>
. Could the new way stack ghci finds dependencies be added some way to stack-ide?
For the moment, I am adding an other-modules list for the executable to workaround this, works for me.
I added support for this in stack ghci
. I'll add it to stack-ide soon.
as usual, big thanks !
So does stack-ide only support library
components currently?
No, it just needs a way in its UI to disambiguate Main modules between components.
Closing as dupe of #63 which describes the point accurately.
I noticed that stack-ide doesn't seem to track files in executable targets (i.e. when I run
stack ide myproject
it only compiles/reports errors for the "library" section of the cabal file). Is there a way to do this?(including test-suites would be great too)