doc: add and improve comments

This commit is contained in:
Sebastian Mark 2024-10-30 11:03:18 +01:00
parent 6187122b81
commit f19ab81dc8
11 changed files with 31 additions and 8 deletions

View file

@ -25,6 +25,7 @@ var (
func Start() {
flag.Parse()
// show/hide cursor for nicer interface
cursor.Hide()
defer cursor.Show()
@ -45,12 +46,15 @@ func Start() {
config.Password = *parameter_password
}
// Create a client
client := websocket.Connect(config.URL)
client.Password = config.Password
// Receive server messages und update the terminal
channel := make(chan GoTomato.ServerMessage)
go client.ProcessServerMessages(channel)
frontend.UpdateLoop(client, config, channel)
// disconnect from server
client.Disconnect()
}