-
Notifications
You must be signed in to change notification settings - Fork 1
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
Bad UX of starting for the first time in a project (takes too long with no feedback) #4
Comments
It’s not a big problem with official Stack, as all the commands return almost instantly. But when using intero-nix-shim as I don’t know what to do with this w/o massive changes in intero.el. Hmmmmm. It would be good if we could unmask Nix’s output when resolving the deps (now it goes to /dev/null) and have it displayed somewhere in Emacs in case of an error. That could work now without many (any?) changes, requiring Nix to be called only for I’ll investigate. |
Couldn't intero-nix-shim itself just call out to ghc etc. directly, trusting that ghc in PATH is set properly for the packages? e.g. using nix-buffer or similar? |
Sure. :) But it’s calculating this PATH that takes so long (at least initially)! And, unfortunately, this calculation is currently run synchronously. If we could fake outputs of initial calls to |
If we cannot fake them, the only option I see is changing intero.el itself… And this doesn’t feel like a small diff. :( |
Right, but my suggestion is that intero-nix-shim shouldn't be calculating this path at all, and we can use nix-buffer to a) asynrchronously do the nix-build, with caching (it already does) and b) enable intero once the PATH is set up (which, due to the caching, will be right away except for the very first time you ever open a file in that project) |
Ah, I get it now, sorry! :)
|
For the first bullet point yes, or maybe just a recommended configuration in ~/.emacs. I'm not sure what |
It just runs GHCi for the current project, similar to their |
Especially if the project pins a specific Nixpkgs SHA1, which you don’t have locally.
Quick workaround: run
intero-nix-shim ghci
in a terminal, in the project’s root directory.Idea: maybe we could reuse that buffer Intero+Stack is using for auto-installation, without changes to Intero.el, but I don’t know how.
The text was updated successfully, but these errors were encountered: