Skip to content
This repository has been archived by the owner on Apr 13, 2024. It is now read-only.

Commit

Permalink
all: Replace URL of golang.org with using HTTPS
Browse files Browse the repository at this point in the history
Change-Id: Ifa5acf5c6ca3ca67c44e7cf6f1c3eaadeb921da6
Reviewed-on: https://go-review.googlesource.com/90055
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
  • Loading branch information
ykzts authored and OlingCat committed Mar 24, 2018
1 parent 5cbbbaf commit f8ec6d0
Show file tree
Hide file tree
Showing 8 changed files with 55 additions and 55 deletions.
2 changes: 1 addition & 1 deletion AUTHORS
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# This source code refers to The Go Authors for copyright purposes.
# The master list of authors is in the main Go distribution,
# visible at http://tip.golang.org/AUTHORS.
# visible at https://tip.golang.org/AUTHORS.
2 changes: 1 addition & 1 deletion CONTRIBUTORS
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# This source code was written by the Go contributors.
# The master list of contributors is in the main Go distribution,
# visible at http://tip.golang.org/CONTRIBUTORS.
# visible at https://tip.golang.org/CONTRIBUTORS.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,4 +21,4 @@

除特别声明外,go-tour 源码文件均采用 BSD 风格的授权许可分发,许可内容见 `LICENSE` 文件。

贡献方式应与 Go 项目遵循相同的流程:http://go-zh.org/doc/contribute.html
贡献方式应与 Go 项目遵循相同的流程:http://go-zh.org/doc/contribute.html
30 changes: 15 additions & 15 deletions content/concurrency/exercise-web-crawler.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func Crawl(url string, depth int, fetcher Fetcher) {
}

func main() {
Crawl("http://golang.org/", 4, fetcher)
Crawl("https://golang.org/", 4, fetcher)
}

// fakeFetcher 是返回若干结果的 Fetcher。
Expand All @@ -52,34 +52,34 @@ func (f fakeFetcher) Fetch(url string) (string, []string, error) {

// fetcher 是填充后的 fakeFetcher。
var fetcher = fakeFetcher{
"http://golang.org/": &fakeResult{
"https://golang.org/": &fakeResult{
"The Go Programming Language",
[]string{
"http://golang.org/pkg/",
"http://golang.org/cmd/",
"https://golang.org/pkg/",
"https://golang.org/cmd/",
},
},
"http://golang.org/pkg/": &fakeResult{
"https://golang.org/pkg/": &fakeResult{
"Packages",
[]string{
"http://golang.org/",
"http://golang.org/cmd/",
"http://golang.org/pkg/fmt/",
"http://golang.org/pkg/os/",
"https://golang.org/",
"https://golang.org/cmd/",
"https://golang.org/pkg/fmt/",
"https://golang.org/pkg/os/",
},
},
"http://golang.org/pkg/fmt/": &fakeResult{
"https://golang.org/pkg/fmt/": &fakeResult{
"Package fmt",
[]string{
"http://golang.org/",
"http://golang.org/pkg/",
"https://golang.org/",
"https://golang.org/pkg/",
},
},
"http://golang.org/pkg/os/": &fakeResult{
"https://golang.org/pkg/os/": &fakeResult{
"Package os",
[]string{
"http://golang.org/",
"http://golang.org/pkg/",
"https://golang.org/",
"https://golang.org/pkg/",
},
},
}
38 changes: 19 additions & 19 deletions content/welcome.article
Original file line number Diff line number Diff line change
Expand Up @@ -60,48 +60,48 @@ https://go-zh.org
点击[[javascript:highlightAndClick(".next-page")][“下一页”]]按钮或者按 `PageDown` 键继续。

#appengine: * Go 离线版
#appengine:
#appengine:
#appengine: 本指南也可作为独立的程序使用,这样你无需访问互联网就能运行它。
#appengine:
#appengine:
#appengine: 独立版的指南更快,因为它会在你的机器上构建并运行代码示例。
#appengine:
#appengine:
#appengine: 要在本地运行此教程的中文版,首先请[[https://golang.org/dl/][下载并安装 Go]],
#appengine: 然后用 [[https://go-zh.org/cmd/go/][go get]] 命令来安装
#appengine: [[https://go-zh.org/x/tour/][gotour]]:
#appengine:
#appengine:
#appengine: go get github.com/Go-zh/tour/gotour
#appengine:
#appengine:
#appengine: 最后运行产生的 `gotour` 可执行文件。
#appengine:
#appengine:
#appengine: 如果要运行本教程的英文版,首先请[[https://golang.org/dl/][下载并安装 Go]],接着从命令行启动教程:
#appengine:
#appengine:
#appengine: go tool tour
#appengine:
#appengine:
#appengine: 如果上面的方式遇到了问题,并且你能够直接访问 Google 的服务器,那么你也可以手动安装并运行本教程:
#appengine:
#appengine:
#appengine: go get golang.org/x/tour/gotour
#appengine: gotour
#appengine:
#appengine:
#appengine: 该程序会打开 Web 浏览器来显示本教程的本地英文版。
#appengine:
#appengine:
#appengine: 当然,你也可以继续在线学习本教程。

#appengine: * Go 练习场
#appengine:
#appengine:
#appengine: 本指南构建在 [[https://play.golang.org/][Go 练习场]]上,它是一个运行在 [[https://golang.org/][golang.org]] 服务器上的一个 Web 服务。
#appengine:
#appengine:
#appengine: 该服务会接收一个 Go 程序,然后在沙盒中编译、链接并运行它,最后返回输出。
#appengine:
#appengine:
#appengine: 在练习场中运行的程序有一些限制:
#appengine:
#appengine:
#appengine: - 练习场中的时间始于 2009-11-10 23:00:00 UTC(这个日期的含义留给读者去发现)。赋予程序确定的输出能让缓存程序更加容易。
#appengine:
#appengine:
#appengine: - 程序的执行时间、CPU 和内存的使用同样也有限制,并且程序不能访问外部网络中的主机。
#appengine:
#appengine:
#appengine: 练习场使用最新发布的 Go 的稳定版本。
#appengine:
#appengine:
#appengine: 参阅 [[https://blog.go-zh.org/playground][Go 练习场的内部机制(英文)]]了解更多信息。
#appengine:
#appengine:
#appengine: .play welcome/sandbox.go

* 恭喜!
Expand Down
2 changes: 1 addition & 1 deletion gotour/appengine.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import (
_ "github.com/Go-zh/tools/playground"
)

const runUrl = "http://golang.org/compile"
const runUrl = "https://golang.org/compile"

func init() {
http.Handle("/lesson/", hstsHandler(lessonHandler))
Expand Down
32 changes: 16 additions & 16 deletions solutions/webcrawler.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ type Fetcher interface {

// fetched tracks URLs that have been (or are being) fetched.
// The lock must be held while reading from or writing to the map.
// See http://golang.org/ref/spec#Struct_types section on embedded types.
// See https://golang.org/ref/spec#Struct_types section on embedded types.
var fetched = struct {
m map[string]error
sync.Mutex
Expand Down Expand Up @@ -75,7 +75,7 @@ func Crawl(url string, depth int, fetcher Fetcher) {
}

func main() {
Crawl("http://golang.org/", 4, fetcher)
Crawl("https://golang.org/", 4, fetcher)

fmt.Println("Fetching stats\n--------------")
for url, err := range fetched.m {
Expand Down Expand Up @@ -104,34 +104,34 @@ func (f *fakeFetcher) Fetch(url string) (string, []string, error) {

// fetcher is a populated fakeFetcher.
var fetcher = &fakeFetcher{
"http://golang.org/": &fakeResult{
"https://golang.org/": &fakeResult{
"The Go Programming Language",
[]string{
"http://golang.org/pkg/",
"http://golang.org/cmd/",
"https://golang.org/pkg/",
"https://golang.org/cmd/",
},
},
"http://golang.org/pkg/": &fakeResult{
"https://golang.org/pkg/": &fakeResult{
"Packages",
[]string{
"http://golang.org/",
"http://golang.org/cmd/",
"http://golang.org/pkg/fmt/",
"http://golang.org/pkg/os/",
"https://golang.org/",
"https://golang.org/cmd/",
"https://golang.org/pkg/fmt/",
"https://golang.org/pkg/os/",
},
},
"http://golang.org/pkg/fmt/": &fakeResult{
"https://golang.org/pkg/fmt/": &fakeResult{
"Package fmt",
[]string{
"http://golang.org/",
"http://golang.org/pkg/",
"https://golang.org/",
"https://golang.org/pkg/",
},
},
"http://golang.org/pkg/os/": &fakeResult{
"https://golang.org/pkg/os/": &fakeResult{
"Package os",
[]string{
"http://golang.org/",
"http://golang.org/pkg/",
"https://golang.org/",
"https://golang.org/pkg/",
},
},
}
2 changes: 1 addition & 1 deletion static/js/values.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ angular.module('tour.values', []).
value('tableOfContents', [{
'id': 'mechanics',
'title': '指南的使用',
'description': '<p>欢迎来到 <a href="http://golang.org">Go 编程语言</a>指南。本指南涵盖了该语言的大部分重要特性,主要包括:</p>',
'description': '<p>欢迎来到 <a href="https://go-zh.org">Go 编程语言</a>指南。本指南涵盖了该语言的大部分重要特性,主要包括:</p>',
'lessons': ['welcome']
}, {
'id': 'basics',
Expand Down

0 comments on commit f8ec6d0

Please sign in to comment.