-
Notifications
You must be signed in to change notification settings - Fork 20
Option to automatically build ghc-mod and hlint inside Stack-based projects #159
Comments
Recent enough versions of stack (tested with 1.1.2) should generally Automatic builds come with a lot of caveats, I say that from my (admittedly There's also an issue of newcomers to Haskell. Long story short, if ghc-mod Lastly, it's really hard to judge user intent w.r.t. stack vs cabal without What I'm trying to say is, this kind of thing is really, really hard to get PRs are welcome, but for now this is "wontfix". 2016-06-15 16:27 GMT+03:00 varosi [email protected]:
|
This could be an option to choose. I just want to think in a direction for easy to setup Haskell working environment with a few steps. The ideal case will be "Next...Next...Finish". Thanks for the full answer on that. |
Is it possible to make an option to select custom path to ghc-mod depending on GHC version? I mean if current project is built with GHC 7.10.3 to set path to ghd-mod built with it. If I have project with GHC 8.0.1 to use different path to ghc-mod built with this GHC. This will save me a lot of time of rebuilding ghc-mod when I switch projects. Ideally this should work with multiple Haskell projects folders opened in Atom. |
I'll see what I can do. |
Coool! |
This will be great option! It's everyday problem when one works on multiple projects each built with different LTS. |
Actually, working on different projects should "just work", regardless of resolver used, since ghc-mod is installed into snapshot, so all projects using a given resolver can share it... |
Yes, only if it is already installed per project. This is a very common task and it'll be great if it's automated by the IDE. |
This feature of Stack could help a lot on that issue - https://github.com/commercialhaskell/intero/issues/324 |
Other related issue - commercialhaskell/stack#3717 |
Cool. Thanks for the heads-up. |
Great! I have tried it after updating of Atom and plug-ins. But I hit a problem when I deleted ghc-mod installed on PATH. Plug-in failed with:
i.e. it even does not proposed me to build it. The new option is already enabled. May be it is not executed via stack, like:
|
About this problem - stack version could be verified automatically with: stack --version |
To be clear, did you get 'Failed to check compiler versions' error among other things? |
Addition: when I have done:
It executed ghc-mod. So the problem is when it is not built at both places. But later I got:
|
I don't find any "Failed to check compiler versions" message in the console. It's only that exception message. |
See if v2.2.2 works any better. Thanks for testing by the way! |
Thanks for working on this issue! |
Is it possible HLint to be built with ghc-mod, too? It's used in haskell-ghc-mod plug-in and it could be built automatically. |
btw, installing of most recent ghc-mod (8.2.2, 8.2.1, 8.0.2, 8.0.1) could happen on plug-in install time as people expect there to be lost most of installing time. But it's just a proposition. |
I'm testing here at different projects and it's working very well! It's one of the best and useful features of haskell-ghc-mod! |
It's a dependency of ghc-mod. Hence, it's built anyway. And h-g-m doesn't call the binary directly. |
Okay, great! |
I have written about that elsewhere, but this is what EclipseFP was doing before in Eclipse for cabal-based projects into a sandbox. It think that this will help with easier use of atom-haskell and closer to "just works" concept.
If we're using multiple projects inside same Atom editor - it could use different ghc-mod executables for each project depending on its stack resolver.
Currently I do this by hand each time outside Atom.
The text was updated successfully, but these errors were encountered: