Fork me on GitHub
#cursive
<
2021-07-02
>
tony.kay19:07:54

Hey @cfleming , related to Code With Me and Code Together: not sure if you thought of this or not, but both of those have the ability to share the terminal window on the network. I know it would not be terribly feature-rich, but if it is relatively easy to send stuff from the editor to a terminal, that might be a good way to use a REPL running in a terminal as an 80% soln for pairing.

👍 3
onetom04:07:22

I would be really happy with such a "fallback" solution too! It would similar to what https://github.com/clojure-emacs/inf-clojure does.

onetom04:07:17

Such an "escape hatch" would also allow running REPLs in custom ways. For example, I just wanted to provide some JVM properties to the remote nREPL client Cursive would start, but such option is only available for local REPL run configs. More specifically, I wanted the REPL client to go through a SOCKS5 proxy, so I can connect to Datomic Cloud ion server:

clj -J-DsocksProxyHost=localhost -J-DsocksProxyPort=8182 -M:nREPL:client --host entry.datomic-cloud-system-name.ap-
 --port 3001
This way, I would only need to do an ssh -D 8182 ec2-user@datomic-cloud-bastion and don't worry about tunnelling individual ports. Another use-case would be to specify the NREPL_CONFIG_DIR (https://nrepl.org/nrepl/0.8/usage/server.html#server-options), so we can configure the nREPL client in different ways, BUT the remote REPL config doesn't have the environment config option either.

cfleming01:07:42

@U0CKQ19AQ Interesting idea, and that might work well. I’d have to think about what it even means to have a REPL open on the terminal, since Cursive wouldn’t be starting the REPL at that point. I’m not sure how the user would indicate “I now have a REPL open in my terminal and I want all REPL commands to go there”.

cfleming01:07:44

@U086D6TBN I’ll look at that too - I suspect the issue would be that Cursive doesn’t actually start a new process for the remote REPL client but runs it in-process (IIRC). However I may be able to pass that config directly to nREPL in that case.

👍 2
tony.kay05:07:07

Seems like send form to terminal would be sufficient...no matter what is running there. Just a new command altogether

cfleming08:07:40

Maybe a new output option for REPL commands, then you could build the commands you needed.

cfleming00:07:47

Actually, apparently the latest EAP has support for using Code With Me with custom toolwindows like the REPL. I’ll add that and hopefully it’ll work!

👍 3