diff --git a/README.md b/README.md index 48cd663..69b2ebc 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Imitation is the sincerest form of flattery. But seriously, https://github.com/reorx/httpstat is the new hotness, and this is a shameless rip off. ## Installation -`httpstat` requires Go 1.11 or later. +`httpstat` requires Go 1.13 or later. ``` $ go get github.com/davecheney/httpstat ``` diff --git a/main.go b/main.go index a83f301..115836b 100644 --- a/main.go +++ b/main.go @@ -22,8 +22,6 @@ import ( "strings" "time" - "golang.org/x/net/http2" - "github.com/fatih/color" ) @@ -253,6 +251,7 @@ func visit(url *url.URL) { IdleConnTimeout: 90 * time.Second, TLSHandshakeTimeout: 10 * time.Second, ExpectContinueTimeout: 1 * time.Second, + ForceAttemptHTTP2: true, } switch { @@ -274,13 +273,6 @@ func visit(url *url.URL) { InsecureSkipVerify: insecure, Certificates: readClientCert(clientCertFile), } - - // Because we create a custom TLSClientConfig, we have to opt-in to HTTP/2. - // See https://github.com/golang/go/issues/14275 - err = http2.ConfigureTransport(tr) - if err != nil { - log.Fatalf("failed to prepare transport for HTTP/2: %v", err) - } } client := &http.Client{