21 lines
430 B
Go
21 lines
430 B
Go
package common
|
|
|
|
import "fmt"
|
|
|
|
const (
|
|
StatusReady = "READY"
|
|
StatusConnecting = "CONNECTING"
|
|
StatusReconnecting = "RECONNECTING"
|
|
StatusTunnelConnected = "TUNNEL_CONNECTED"
|
|
StatusTunnelLost = "TUNNEL_LOST"
|
|
StatusError = "ERROR"
|
|
)
|
|
|
|
func EmitStatus(status string) {
|
|
fmt.Printf("STATUS:%s\n", status)
|
|
}
|
|
|
|
func EmitStatusError(msg string) {
|
|
fmt.Printf("STATUS:%s:%s\n", StatusError, msg)
|
|
}
|