aboutsummaryrefslogtreecommitdiff
path: root/cmd/golangorg/server.go
diff options
context:
space:
mode:
authorDmitri Shuralyov <dmitshur@golang.org>2021-08-27 18:06:53 -0500
committerDmitri Shuralyov <dmitshur@google.com>2022-01-04 19:56:33 +0000
commit2b23ec4809fbb9dabc982f7662a75ff4f14d8f8e (patch)
treec3df9c38f23e1b67e24b260ee8e9d83239179353 /cmd/golangorg/server.go
parent995577f14f28bed40e5f61132f1b78adbdbbb3d9 (diff)
downloadgo-x-website-2b23ec4809fbb9dabc982f7662a75ff4f14d8f8e.tar.xz
website: 2022 and onwards are the Years of the Gopher
The Go contribution guide was created in 2009 (commit 38a41eec67e5) as part of the initial public release of Go. It defined the standard copyright header for files in the Go tree. Since files are copyrighted the year they are added, having the current year in the header means it can be copied and pasted into newly created files without further modification. Given the year (2009 at the time) was written in a plain HTML file, it needed to be updated every year to stay current. Over the last 12 years, gophers assembled and performed this task: • commit 38a41eec67e5 contribute.html (initial commit) • go.dev/cl/184055 doc/contribute.html: change copyright year • go.dev/cl/3907042 doc: contribution copyright year 2011 • go.dev/cl/5531048 doc: use 2012 for year in model standard copyright header • go.dev/cl/7034044 doc: update standard copyright header • go.dev/cl/46660043 2014: Year of the Gopher. • go.dev/cl/2087 doc: 2015 will be the Year of the Gopher. • go.dev/cl/18117 doc: 2016 is the Year of the Gopher. • go.dev/cl/35240 doc: 2017 is the Year of the Gopher • go.dev/cl/85775 doc: 2018 is the Year of the Gopher • go.dev/cl/155928 doc: 2019 is the Year of the Gopher • go.dev/cl/213017 doc: 2020 is the Year of the Gopher • go.dev/cl/280163 doc: 2021 is the Year of the Gopher In a way, this yearly tradition of updating HTML by hand was fun¹, but we've now reached a convenient time to share the joy with our friendly robot gophers. Previously, the contribution guide lived in the main Go repository, and a part of the website serving code was still in x/tools/godoc. In 2021, Russ consolidated the remaining Go website content and code all in x/website (for example, see CL 291693 and CL 293420). So now everything we need is in one repo, making this trivial to automate, and in doing so mark 2022 and beyond as the Years of the Gopher. ¹ See the commit messages and conversations in the linked CLs. Change-Id: Ieab904b77d764c3e191f75923369ce461d7102c6 Reviewed-on: https://go-review.googlesource.com/c/website/+/375056 Run-TryBot: Dmitri Shuralyov <dmitshur@golang.org> Trust: Dmitri Shuralyov <dmitshur@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Jamal Carvalho <jamalcarvalho@google.com>
Diffstat (limited to 'cmd/golangorg/server.go')
-rw-r--r--cmd/golangorg/server.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/cmd/golangorg/server.go b/cmd/golangorg/server.go
index 2b154b35..6e1b3718 100644
--- a/cmd/golangorg/server.go
+++ b/cmd/golangorg/server.go
@@ -255,6 +255,7 @@ func newSite(mux *http.ServeMux, host string, content, goroot fs.FS) (*web.Site,
"releases": func() []*history.Major { return history.Majors },
"section": section,
"version": func() string { return runtime.Version() },
+ "now": func() time.Time { return time.Now() },
})
docs, err := pkgdoc.NewServer(fsys, site, googleCN)
if err != nil {