conspy: Take command of your command line

I can think of plenty of ways to use conspy, but I can’t really think of one that shows it in action, except perhaps for this.


It might take a few seconds to see what conspy is doing there: That’s the vc2 login on my Arch system, reproduced exactly in a terminal emulator.

In other words, you get a faithful rendition of what’s in the virtual console, inside another terminal instance. This might remind you of something like screen -x, but it’s quite different.

It’s terribly clever, and I know I’ve used it in the past, even if I don’t think I made a note of it either here or on the old blog. Which is an oversight, and I should apologize.

conspy allows you to send keystrokes to a tty too, which is probably where it might come in most handy. So you could, in theory, send commands to a vc that is either inaccessible or remote. And pairing this with ssh means you probably have an extra layer of control.

There are some obvious question marks that arise. For one, you might wonder at the usefulness of conspy if either your terminal or your console is of dramatically different dimensions.

For what I’ve seen, conspy plays it safe by leaving excess space blank when you have it, and by arbitrarily cutting off the display when you don’t. I haven’t tried resetting or resizing a framebuffer with conspy, and I don’t know if you’d have much luck using conspy with a framebuffer emulator. I leave it to you to pursue those options.

I also notice some discrepancies in what a virtual console shows, and what conspy can display. Even just htop has a few oddball characters in conspy, that otherwise look fine in the tty.

And sometimes there’s a little lag between sending characters through conspy and their appearance on the screen. It could just be the side effect of working with a machine that is out-of-date by more than a decade, but it’s something I see.

None of those issues hamstrings conspy in the least though, since conspy allows you to effectively peer into a vc, or even issue commands through it, from far away. That kind of usefulness — and its apparent freedom from other tools that might let you do something similar, like screen — make it a valuable tool in its own right.

1 thought on “conspy: Take command of your command line

  1. Pingback: Bonus: A dozen more remainders | Inconsolation

Comments are closed.