Console-based chat across machines with kids
My kids wanted to try online chat so of course I obliged.
First I installed Tailscale on all our computers: my M1 Mac Mini running OS X and their Xubuntu laptops. That allowed us to connect to each other’s computers via friendly hostnames instead of needing to use IP addresses or remembering the unwieldy hostnames generated by the wifi router.
My initial attempt was to use the write command to send messages to each other while logged into the same machine but that had the annoying side-effect of inserting incoming messages into the midst of what the recipient was doing, particularly messages being composed asynchronously.
I decided to try using the venerable Unix talk instead. Accordingly, I enabled the ntalk daemon on my Mac Mini using the following command.
sudo launchctl load -w /System/Library/LaunchDaemons/ntalk.plist
After that it was a simple matter of installing talk (and talkd) on their laptops via apt. Then we could easily set up 2-way chat sessions by typing commands on each computer. On the kids’ laptops, we used something like this:
kid@kidbox: $ talk tony@mac-daddy
And on mine we used one like this:
tony@mac-daddy ~ % talk kid@kidbox
The result was a nice console session for each of us where we could compose messages on a line while incoming messages appeared in a separate pane instead of overwriting what we were in the midst of typing.