]> Cypherpunks repositories - gostls13.git/commitdiff
doc/go1.14: document changes to -mod=readonly and go.mod file maintenance
authorBryan C. Mills <bcmills@google.com>
Tue, 17 Dec 2019 19:41:45 +0000 (14:41 -0500)
committerBryan C. Mills <bcmills@google.com>
Tue, 17 Dec 2019 20:57:06 +0000 (20:57 +0000)
Fixes #36169

Change-Id: Ib9a53fdb0112635b53be38d6818834dd1775e70c
Reviewed-on: https://go-review.googlesource.com/c/go/+/211698
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Jay Conrod <jayconrod@google.com>
doc/go1.14.html

index 7a5aff574a7ecb6b5e6c8fb3814d369890c0bc85..e7cd53390851e37d2bf08a8b0a7b8f7e048173a5 100644 (file)
@@ -124,6 +124,11 @@ TODO
   <a href="https://golang.org/issue/32502">caused the build to fail</a>.
 </p>
 
+<p><!-- golang.org/issue/33326 -->
+  <code>-mod=readonly</code> is now set by default when the <code>go.mod</code>
+  file is read-only and no top-level <code>vendor</code> directory is present.
+</p>
+
 <p><!-- golang.org/issue/31481 -->
   <code>-modcacherw</code> is a new flag that instructs the <code>go</code>
   command to leave newly-created directories in the module cache at their
@@ -159,6 +164,30 @@ TODO
   include them if reported by a proxy.
 </p>
 
+
+<h4 id="go.mod"><code>go.mod</code> file maintenance</h4>
+<!-- golang.org/issue/34822 -->
+
+<p>
+  <code>go</code> commands other than
+  <code>go</code> <code>mod</code> <code>tidy</code> no longer
+  remove a <code>require</code> directive that specifies a version of an indirect dependency
+  that is already implied by other (transitive) dependencies of the main
+  module.
+</p>
+
+<p>
+  <code>go</code> commands other than
+  <code>go</code> <code>mod</code> <code>tidy</code> no longer
+  edit the <code>go.mod</code> file if the changes are only cosmetic.
+</p>
+
+<p>
+  When <code>-mod=readonly</code> is set, <code>go</code> commands will no
+  longer fail due to a missing <code>go</code> directive or erroneous
+  <code>// indirect</code> comment.
+</p>
+
 <h4 id="module-downloading">Module downloading</h4>
 
 <p><!-- golang.org/issue/26092 -->