Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
These packages are not meant to be used; they exist only to test the go command in various scenarios.
- Loading branch information
Showing
1 changed file
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package main | ||
|
||
import ( | ||
"io" | ||
"net/http" | ||
) | ||
|
||
func init() { | ||
// For golang.org/issue/18660. | ||
{ | ||
h := func(w http.ResponseWriter, req *http.Request) { | ||
w.Header().Set("Content-Type", "text/plain; charset=utf-8") | ||
io.WriteString(w, `<meta name="go-import" content="dmitri.shuralyov.com/test/go-get-issue-unicode git https://github.com/dmitshur-test/go-get-issue-unicode">`) | ||
} | ||
http.HandleFunc("/test/go-get-issue-unicode", h) | ||
http.HandleFunc("/test/go-get-issue-unicode/испытание", h) | ||
} | ||
|
||
// For own module learning. | ||
{ | ||
h := func(w http.ResponseWriter, req *http.Request) { | ||
w.Header().Set("Content-Type", "text/plain; charset=utf-8") | ||
io.WriteString(w, `<meta name="go-import" content="dmitri.shuralyov.com/test/modtest1 mod https://dmitri.shuralyov.com/test/moduleproxy">`) | ||
} | ||
http.HandleFunc("/test/modtest1", h) | ||
http.HandleFunc("/test/modtest1/inner", h) | ||
http.HandleFunc("/test/modtest1/inner/p", h) | ||
} | ||
} |