Closed saep closed 5 years ago
do you actually use the reloading mechanism? It just seems rather exotic to implement this from the inside without sufficient demand.
FYI, in my implementation I use stack build --dry-run
to determine whether the project needs to be rebuilt.
Also, why not stack exec
?
I don't like restarting my editor all the time. A working function to compile and restart a plugin host is probably enough, though.
stack exec
takes 2-3 seconds on my laptop to start executing. stack build --dry-run
takes 2-3 seconds as well. I want my editor to start fast. :-)
fair enough! although it's only .3 seconds for the second time, which is still a number, I guess. but I want to point out that not restarting and having immediate startup are counterintuitive requirements ;) In any case, this looks great!
It's always 2-3 seconds for me. It might be my 6 year old laptop or something that has to do with the nix-integration.
Thank you for the review!
FYI, I successfully started my plugins with nvim-hs.vim (using nvim-hs-1.0.0.2 though)
The general idea originally came from @tek .
Since it can be difficult/impossible with the current design to install plugins next to each other if they need different versions of the the same dependency, starting multiple nvim-hs instances seems like a good way to get around this.
Together with the scripts from the new repository nvim-hs.vim, multiple nvim-hs instance can be started next to each other. With a little bit of simple boilerplate, nvim-hs plugins can also be shipped like regular neovim plugins.
To use my ghcid plugin with vim-plugged, you will simply need the following in your neovim config:
You can still use a personal Haskell project to combine plugins. However, since the scripts above usually start an nvim-hs plugin host faster than the sandboxed Dyre setups I used, I also remoed Dyre as a dependency. A mechanism to reload changed configuration files doesn't exist yet.
TODO