Skip to content

Commit be1dfb0

Browse files
committed
doc: describe modules in Go 1.11 release notes and Go FAQ
Fixes #25517. Change-Id: I801eebe17eaed9be09f290e8f219a808dc98f837 Reviewed-on: https://go-review.googlesource.com/122408 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Reviewed-by: Andrew Bonventre <andybons@golang.org>
1 parent fb72965 commit be1dfb0

File tree

2 files changed

+53
-9
lines changed

2 files changed

+53
-9
lines changed

Diff for: doc/go1.11.html

+47-4
Original file line numberDiff line numberDiff line change
@@ -53,18 +53,61 @@ <h2 id="ports">Ports</h2>
5353
TODO: PPC64LE race detector support
5454
</p>
5555

56-
<h3 id="package-versioning">Package Versioning (vgo)</h3>
56+
<h3 id="wasm">WebAssembly</h3>
57+
<p>
58+
Go 1.11 adds an experimental port to WebAssembly (<code>js/wasm</code>).
59+
</p>
60+
61+
<h2 id="tools">Tools</h2>
62+
63+
<h3 id="modules">Modules, package versioning, and dependency management</h3>
5764
<p>
5865
<strong>
5966
NOTE: This is not present in go1.11beta1 but will be available in future
6067
betas and subsequent releases.
6168
</strong>
62-
Go 1.11 adds experimental, integrated support for package versioning.
69+
Go 1.11 adds experimental support for a new concept called “modules,”
70+
an alternative to GOPATH with integrated support for versioning and
71+
package distribution.
72+
Using modules, developers are no longer confined to working inside GOPATH,
73+
version dependency information is explicit yet lightweight,
74+
and builds are more reliable and reproducible.
6375
</p>
6476

65-
<h3 id="wasm">WebAssembly</h3>
6677
<p>
67-
Go 1.11 adds an experimental port to WebAssembly (<code>js/wasm</code>).
78+
Module support is considered experimental.
79+
Details are likely to change in response to feedback from Go 1.11 users,
80+
and we have more tools planned.
81+
Although the details of module support may change, projects that convert
82+
to modules using Go 1.11 will continue to work with Go 1.12 and later.
83+
If you encounter bugs using modules,
84+
please <a href="https://golang.org/issue/new">file issues</a>
85+
so we can fix them.
86+
</p>
87+
88+
<p>
89+
TODO: Link to intro doc.
90+
</p>
91+
92+
<h3 id="gopackages">Package loading</h2>
93+
94+
<p>
95+
TODO: Note about go/build versus golang.org/x/tools/go/packages.
96+
</p>
97+
98+
<h3 id="gocache">Build cache requirement</h2>
99+
100+
<p>
101+
Go 1.11 will be the last release to support setting the environment
102+
variable <code>GOCACHE=off</code> to disable the
103+
<a href="/cmd/go/#hdr-Build_and_test_caching">build cache</a>,
104+
introduced in Go 1.10.
105+
Starting in Go 1.12, the build cache will be required,
106+
as a step toward eliminating <code>$GOPATH/pkg</code>.
107+
The module and package loading support described above
108+
already require that the build cache be enabled.
109+
If you have disabled the build cache to avoid problems you encountered,
110+
please <a href="https://golang.org/issue/new">file an issue</a> to let us know about them.
68111
</p>
69112

70113
<h2 id="library">Core library</h2>

Diff for: doc/go_faq.html

+6-5
Original file line numberDiff line numberDiff line change
@@ -1153,18 +1153,19 @@ <h3 id="get_version">
11531153

11541154
<p>
11551155
The Go 1.5 release added a facility to the
1156-
<a href="https://golang.org/cmd/go">go</a> command
1156+
<a href="https://golang.org/cmd/go"><code>go</code></a> command
11571157
that makes it easier to manage external dependencies by "vendoring"
11581158
them into a special directory near the package that depends upon them.
11591159
See the <a href="https://golang.org/s/go15vendor">design
11601160
document</a> for details.
11611161
</p>
11621162

11631163
<p>
1164-
Work is underway on an experimental package management tool,
1165-
<a href="https://github.com/golang/dep"><code>dep</code></a>, to learn
1166-
more about how tooling can help package management. More information can be found in
1167-
<a href="https://github.com/golang/dep/blob/master/docs/FAQ.md">the <code>dep</code> FAQ</a>.
1164+
The Go 1.11 release added new, experimental support
1165+
for package versioning to the <code>go</code> command,
1166+
in the form of Go modules.
1167+
For more information, see the <a href="/doc/go1.11#modules">Go 1.11 release notes</a>
1168+
and the <a href="/cmd/go#hdr-Modules__module_versions__and_more"><code>go</code> command documentation</a>.
11681169
</p>
11691170

11701171
<h2 id="Pointers">Pointers and Allocation</h2>

0 commit comments

Comments
 (0)