From 9204c968d1beffaaed55415d2dcdf5507316d301 Mon Sep 17 00:00:00 2001 From: re Date: Mon, 12 Dec 2022 15:36:04 +0300 Subject: [PATCH] fix repos --- .circleci/config.yml | 2 +- README.md | 16 ++++++++-------- example_test.go | 2 +- examples/autobahn/server.go | 2 +- examples/chat/README.md | 14 +++++++------- examples/chat/client.go | 2 +- examples/command/README.md | 4 ++-- examples/command/main.go | 2 +- examples/echo/client.go | 2 +- examples/echo/server.go | 2 +- examples/filewatch/README.md | 4 ++-- examples/filewatch/main.go | 4 ++-- go.mod | 2 +- 13 files changed, 29 insertions(+), 29 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ecb33f6..bff8262 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -17,7 +17,7 @@ jobs: default: "" docker: - image: "cimg/go:<< parameters.version >>" - working_directory: /home/circleci/project/go/src/github.com/gorilla/websocket + working_directory: /home/circleci/project/go/src/git.internal/re/websocket environment: GO111MODULE: "on" GOPROXY: "<< parameters.goproxy >>" diff --git a/README.md b/README.md index 4484ac1..2d8ed1e 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ # Gorilla WebSocket -[![GoDoc](https://godoc.org/github.com/gorilla/websocket?status.svg)](https://godoc.org/github.com/gorilla/websocket) +[![GoDoc](https://godoc.org/git.internal/re/websocket?status.svg)](https://godoc.org/git.internal/re/websocket) [![CircleCI](https://circleci.com/gh/gorilla/websocket.svg?style=svg)](https://circleci.com/gh/gorilla/websocket) Gorilla WebSocket is a [Go](http://golang.org/) implementation of the @@ -14,11 +14,11 @@ Gorilla WebSocket is a [Go](http://golang.org/) implementation of the ### Documentation -* [API Reference](https://pkg.go.dev/github.com/gorilla/websocket?tab=doc) -* [Chat example](https://github.com/gorilla/websocket/tree/master/examples/chat) -* [Command example](https://github.com/gorilla/websocket/tree/master/examples/command) -* [Client and server example](https://github.com/gorilla/websocket/tree/master/examples/echo) -* [File watch example](https://github.com/gorilla/websocket/tree/master/examples/filewatch) +* [API Reference](https://pkg.go.dev/git.internal/re/websocket?tab=doc) +* [Chat example](https://git.internal/re/websocket/tree/master/examples/chat) +* [Command example](https://git.internal/re/websocket/tree/master/examples/command) +* [Client and server example](https://git.internal/re/websocket/tree/master/examples/echo) +* [File watch example](https://git.internal/re/websocket/tree/master/examples/filewatch) ### Status @@ -28,11 +28,11 @@ package API is stable. ### Installation - go get github.com/gorilla/websocket + go get git.internal/re/websocket ### Protocol Compliance The Gorilla WebSocket package passes the server tests in the [Autobahn Test Suite](https://github.com/crossbario/autobahn-testsuite) using the application in the [examples/autobahn -subdirectory](https://github.com/gorilla/websocket/tree/master/examples/autobahn). +subdirectory](https://git.internal/re/websocket/tree/master/examples/autobahn). diff --git a/example_test.go b/example_test.go index cd1883b..ea2b813 100644 --- a/example_test.go +++ b/example_test.go @@ -9,7 +9,7 @@ import ( "net/http" "testing" - "github.com/gorilla/websocket" + "git.internal/re/websocket" ) var ( diff --git a/examples/autobahn/server.go b/examples/autobahn/server.go index 8b17fe3..1bd474e 100644 --- a/examples/autobahn/server.go +++ b/examples/autobahn/server.go @@ -14,7 +14,7 @@ import ( "time" "unicode/utf8" - "github.com/gorilla/websocket" + "git.internal/re/websocket" ) var upgrader = websocket.Upgrader{ diff --git a/examples/chat/README.md b/examples/chat/README.md index 7baf3e3..ca5bd30 100644 --- a/examples/chat/README.md +++ b/examples/chat/README.md @@ -1,7 +1,7 @@ # Chat Example This application shows how to use the -[websocket](https://github.com/gorilla/websocket) package to implement a simple +[websocket](https://git.internal/re/websocket) package to implement a simple web chat application. ## Running the example @@ -13,8 +13,8 @@ development environment. Once you have Go up and running, you can download, build and run the example using the following commands. - $ go get github.com/gorilla/websocket - $ cd `go list -f '{{.Dir}}' github.com/gorilla/websocket/examples/chat` + $ go get git.internal/re/websocket + $ cd `go list -f '{{.Dir}}' git.internal/re/websocket/examples/chat` $ go run *.go To use the chat example, open http://localhost:8080/ in your browser. @@ -38,7 +38,7 @@ sends them to the hub. ### Hub The code for the `Hub` type is in -[hub.go](https://github.com/gorilla/websocket/blob/master/examples/chat/hub.go). +[hub.go](https://git.internal/re/websocket/blob/master/examples/chat/hub.go). The application's `main` function starts the hub's `run` method as a goroutine. Clients send requests to the hub using the `register`, `unregister` and `broadcast` channels. @@ -57,7 +57,7 @@ unregisters the client and closes the websocket. ### Client -The code for the `Client` type is in [client.go](https://github.com/gorilla/websocket/blob/master/examples/chat/client.go). +The code for the `Client` type is in [client.go](https://git.internal/re/websocket/blob/master/examples/chat/client.go). The `serveWs` function is registered by the application's `main` function as an HTTP handler. The handler upgrades the HTTP connection to the WebSocket @@ -73,7 +73,7 @@ Finally, the HTTP handler calls the client's `readPump` method. This method transfers inbound messages from the websocket to the hub. WebSocket connections [support one concurrent reader and one concurrent -writer](https://godoc.org/github.com/gorilla/websocket#hdr-Concurrency). The +writer](https://godoc.org/git.internal/re/websocket#hdr-Concurrency). The application ensures that these concurrency requirements are met by executing all reads from the `readPump` goroutine and all writes from the `writePump` goroutine. @@ -85,7 +85,7 @@ network. ## Frontend -The frontend code is in [home.html](https://github.com/gorilla/websocket/blob/master/examples/chat/home.html). +The frontend code is in [home.html](https://git.internal/re/websocket/blob/master/examples/chat/home.html). On document load, the script checks for websocket functionality in the browser. If websocket functionality is available, then the script opens a connection to diff --git a/examples/chat/client.go b/examples/chat/client.go index 9461c1e..7d4d445 100644 --- a/examples/chat/client.go +++ b/examples/chat/client.go @@ -10,7 +10,7 @@ import ( "net/http" "time" - "github.com/gorilla/websocket" + "git.internal/re/websocket" ) const ( diff --git a/examples/command/README.md b/examples/command/README.md index ed6f786..a16a6c8 100644 --- a/examples/command/README.md +++ b/examples/command/README.md @@ -4,8 +4,8 @@ This example connects a websocket connection to stdin and stdout of a command. Received messages are written to stdin followed by a `\n`. Each line read from standard out is sent as a message to the client. - $ go get github.com/gorilla/websocket - $ cd `go list -f '{{.Dir}}' github.com/gorilla/websocket/examples/command` + $ go get git.internal/re/websocket + $ cd `go list -f '{{.Dir}}' git.internal/re/websocket/examples/command` $ go run main.go # Open http://localhost:8080/ . diff --git a/examples/command/main.go b/examples/command/main.go index 38d9f6c..3586fb6 100644 --- a/examples/command/main.go +++ b/examples/command/main.go @@ -14,7 +14,7 @@ import ( "os/exec" "time" - "github.com/gorilla/websocket" + "git.internal/re/websocket" ) var ( diff --git a/examples/echo/client.go b/examples/echo/client.go index 7d870bd..40c18e2 100644 --- a/examples/echo/client.go +++ b/examples/echo/client.go @@ -15,7 +15,7 @@ import ( "os/signal" "time" - "github.com/gorilla/websocket" + "git.internal/re/websocket" ) var addr = flag.String("addr", "localhost:8080", "http service address") diff --git a/examples/echo/server.go b/examples/echo/server.go index f9a0b7b..87cc01f 100644 --- a/examples/echo/server.go +++ b/examples/echo/server.go @@ -13,7 +13,7 @@ import ( "log" "net/http" - "github.com/gorilla/websocket" + "git.internal/re/websocket" ) var addr = flag.String("addr", "localhost:8080", "http service address") diff --git a/examples/filewatch/README.md b/examples/filewatch/README.md index ca4931f..5198914 100644 --- a/examples/filewatch/README.md +++ b/examples/filewatch/README.md @@ -2,8 +2,8 @@ This example sends a file to the browser client for display whenever the file is modified. - $ go get github.com/gorilla/websocket - $ cd `go list -f '{{.Dir}}' github.com/gorilla/websocket/examples/filewatch` + $ go get git.internal/re/websocket + $ cd `go list -f '{{.Dir}}' git.internal/re/websocket/examples/filewatch` $ go run main.go # Open http://localhost:8080/ . # Modify the file to see it update in the browser. diff --git a/examples/filewatch/main.go b/examples/filewatch/main.go index d4bf80e..e34de61 100644 --- a/examples/filewatch/main.go +++ b/examples/filewatch/main.go @@ -14,7 +14,7 @@ import ( "strconv" "time" - "github.com/gorilla/websocket" + "git.internal/re/websocket" ) const ( @@ -143,7 +143,7 @@ func serveHome(w http.ResponseWriter, r *http.Request) { p = []byte(err.Error()) lastMod = time.Unix(0, 0) } - var v = struct { + v := struct { Host string Data string LastMod string diff --git a/go.mod b/go.mod index 1a7afd5..03e5834 100644 --- a/go.mod +++ b/go.mod @@ -1,3 +1,3 @@ -module github.com/gorilla/websocket +module git.internal/re/websocket go 1.12