diff --git a/.gitignore b/.gitignore index 543ffdb..4568079 100644 Binary files a/.gitignore and b/.gitignore differ diff --git a/cmd/Client.go b/cmd/client.go similarity index 100% rename from cmd/Client.go rename to cmd/client.go diff --git a/cmd/Cmd.go b/cmd/cmd.go similarity index 100% rename from cmd/Cmd.go rename to cmd/cmd.go diff --git a/cmd/Server.go b/cmd/server.go similarity index 99% rename from cmd/Server.go rename to cmd/server.go index 57e9ba3..152e953 100644 --- a/cmd/Server.go +++ b/cmd/server.go @@ -35,9 +35,7 @@ var clientKeys []int = make([]int, 100) func handleConn(conn *net.TCPConn) { var hs handshake - log.Println("Got a connection!") - // handshake dec := gob.NewDecoder(conn) // Decoder dec.Decode(&hs) @@ -46,13 +44,11 @@ func handleConn(conn *net.TCPConn) { sort.Ints(clientKeys) clients[hs.ID] = goslClient{con: conn, id: hs.ID, w: hs.W, h: hs.H} TotalWidth += hs.W - // conn.Close() } func serveClients() { for { // while true - for _, k := range clientKeys { id, client := k, clients[k] if id > 0 { @@ -60,13 +56,11 @@ func serveClients() { } } time.Sleep(time.Second) - } } func runServer(cmd *cobra.Command, args []string) { fmt.Println("running server ...") - listener, err := net.ListenTCP("tcp", &net.TCPAddr{Port: SERVERPORT}) if err != nil { log.Fatal(err) @@ -82,7 +76,6 @@ func runServer(cmd *cobra.Command, args []string) { } go handleConn(conn) } - } func init() { diff --git a/data/Network.go b/data/network.go similarity index 100% rename from data/Network.go rename to data/network.go diff --git a/data/Screen.go b/data/screen.go similarity index 100% rename from data/Screen.go rename to data/screen.go diff --git a/gosl b/gosl deleted file mode 100755 index 96823ef..0000000 Binary files a/gosl and /dev/null differ diff --git a/Gosl.go b/gosl.go similarity index 100% rename from Gosl.go rename to gosl.go