-
Notifications
You must be signed in to change notification settings - Fork 15
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
Feature request: support REPLish workflow #35
Comments
This is a good idea. |
Instead of focusing on making a repl work, how about making any shell work (since a repl is just a shell). Something like: commands:
- shell: ghci
command: :r
invalidate: *.yaml *.cabal
- shell: nix-shell
command: cabal new-build -j --ghc-options --no-code
invalidate: *.nix |
Oh wow that's a great idea! I could use that at work. |
I've been thinking about this, but getting this to work in just native Haskell maybe hard. Now the output isn't hard as it's just a stdout file handle. But the input is more problematic, see: The solutions offered are either the screen command, or use tmux, for which a client exists: http://hackage.haskell.org/package/chiasma. Maybe tmux is the right approach as this project shouldn't be doing shell management itself? Any thoughts? |
I wonder if a typical ghci workflow can be automated with sos.
Usually you run a ghci process and:
*.hs
changes, you send:r<CR>
or possibly:r<CR>:main<CR>
to ghci*.cabal
or*.yaml
changes, you restart ghciRight now 2. is working perfectly, 3. works kind of weird (I'm not even sure how to describe it) and 1. is not covered at all.
Meanwhile, ghcid supports 1 and 2, but not 3 (by current design) and naturally only supports ghci. Ideally I'd like to be able to use sos to automate a REPL workflow for any language, e.g. restart the process on
project.clj
changes and send(run-all-tests)<CR>
on other changes.The text was updated successfully, but these errors were encountered: