notty icon indicating copy to clipboard operation
notty copied to clipboard

Wishlist : Magic Wormhole

Open lord-re opened this issue 8 years ago • 2 comments

I have a little idea but don't know how it could be done or if it's even doable or not :

The magic wormhole is a fifo between multiple terminal. Let's take an example.

  • You open a terminal. You connect to ssh. You then enter a container with "lxc-attach -n foobar".
  • You open another terminal. You start another ssh session on another machine which can't reach the lxc container.
  • You start/enter/trigger the magic wormhole to bind the two terminal to get data from one term to the other. That way you can transfer files or even pipe commands between the two terminals.

For now you can mimic this with tmux by using buffer copy and all but it's quite complex and not very reliable.

I discussed a bit of this on alacritty's irc channel and was redirected here. What do you think of this ? Is it out of scope ? technically not feasible ?

lord-re avatar Sep 20 '17 20:09 lord-re

Funnily enough, there's a tool with this very name that does this (although via the network) for file transfers: https://magic-wormhole.readthedocs.io

Extending it to support reading from stdin and writing to stdout instead of regular files shouldn't be too difficult either. This doesn't seem like something the terminal needs to support though, unless the hosts in question have no internet access.

lheckemann avatar Feb 23 '18 15:02 lheckemann

The only problem is to how to break the FIFO from the terminal in the middle. Who initiates the break, and how the process should work?

abitrolly avatar May 01 '24 05:05 abitrolly