The bash_chat.cr program allows multiple users to connect to a single server process like a long running interactive bash session or any other program which runs on the command line and do not expect a real tty (e.g. top).
All input from connected clients is sent to the server process and to all other connected clients. The output from the server process is sent to all clients. So you can chat on the bash or even better on the ICR prompt with other users. Coloured output from ICR seems to work.
127.0.0.1:56334 Client sent:
127.0.0.1:56334 Client sent: puts “hello”
icr(0.34.0) > puts “hello”
I hope this is useful.
Have fun with crystal