all. I'm writing a chat client in Go as a proof-of-concept of a library I'm in the process of writing. It needs to take user input and print incoming messages in the same terminal window. Consider the following.
user@debian ~ $ ./client
no session> 192.168.1.100
> Hello, there!
Hi!
> So, did you get that feature working yet?
Nope. I thought you were going to ask on StackOverflow.
>> Yeah, I'm aski
If another message arrives while I'm typing, then it should produce the following.
user@debian ~ $ ./client
no session> 192.168.1.100
> Hello, there!
Hi!
> So, did you get that feature working yet?
Nope. I thought you were going to ask on StackOverflow.
Or did you want me to?
>> Yeah, I'm aski
Is there a way to do this in Go?
Thanks :)