-
Notifications
You must be signed in to change notification settings - Fork 347
Unable to start REPL for specific project component #790
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Can you share your xxx.cabal file?
|
@gracjan, this should do: https://github.com/mrkkrp/mida/blob/master/mida.cabal For example, |
I try to replicate the same issue outside of haskell-mode on the command git clone https://github.com/mrkkrp/mida.git And everything works. cabal repl without arguments should not ever try to Can you help to replicate same issue outside of haskell-mode so that we |
@gracjan, yes it works from command line, Here is what I get:
And here is what should actually happen:
I never liked all these questions on startup but that one about component was useful... |
@gracjan, is it possible to detect component using |
I see. Use And thanks for reporting real life scenario where it is useful to specify arguments to cabal repl. |
This |
@gracjan, as far as I know this is how you select particular executable component. This may be especially useful when you have several executables in one project. |
With haskell-mode, there's (I keep meaning to try and see if it's possible to scan the .cabal file and populate the available list of targets using ido to select...) |
haskell-cabal.el has functions to enumerate sections of a cabal file.
|
@mrkkrp: Can you confirm that setting |
@gracjan, well, yes, but it asks too many questions for my taste (this isn't really a problem, though). Also, please add one space after "build target (empty for default):" and it would really make sense to use completing read and list of build targets extracted from .cabal file when asking about build target. Also, if I press C-g before I finish answering the questions, some REPL buffer is created anyway. I find it confusing. Apart from these issues, it works OK. If you can wait sufficiently long, I can edit all the stuff and open a pull request, but it may take up to month. |
If the problem at hand is fixed then please close this particular issue.
The other things you mention deserve an issue each on their own.
|
Hello. Previously C-c C-l asked me about project component, so I could say
exe:something
and it would work. Now it doesn't ask that but instead just tells me that some packages are hidden. The thing is my executable depends on these packages, while library doesn't, so it seems it tries to start REPL for library and at the same time loads code for executable (that's what I want it to do after all). I'm perplexed, how can I start REPL with respect to dependencies of my executable?The text was updated successfully, but these errors were encountered: