]> Cypherpunks repositories - gostls13.git/commitdiff
cmd/go: fix "go help build -o" docs
authorFilippo Valsorda <filippo@golang.org>
Mon, 19 Aug 2019 17:17:34 +0000 (13:17 -0400)
committerFilippo Valsorda <filippo@golang.org>
Tue, 20 Aug 2019 19:26:11 +0000 (19:26 +0000)
The docs refer to "the last two paragraphs", but in fact should refer to
the first two of the previous three paragraphs. Moved up the out of place
paragraph.

Updates #14295

Change-Id: I066da7a665bc6754d246782b941af214a385017a
Reviewed-on: https://go-review.googlesource.com/c/go/+/190839
Reviewed-by: Bryan C. Mills <bcmills@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@golang.org>
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>

src/cmd/go/alldocs.go
src/cmd/go/internal/work/build.go

index f15ff16abecbfca3f91f90911c454ffc60624bc5..63ec2321be556cff1a8c0b6118a788054336c810 100644 (file)
@@ -78,6 +78,8 @@
 // If the arguments to build are a list of .go files from a single directory,
 // build treats them as a list of source files specifying a single package.
 //
+// When compiling packages, build ignores files that end in '_test.go'.
+//
 // When compiling a single main package, build writes
 // the resulting executable to an output file named after
 // the first source file ('go build ed.go rx.go' writes 'ed' or 'ed.exe')
@@ -88,8 +90,6 @@
 // build compiles the packages but discards the resulting object,
 // serving only as a check that the packages can be built.
 //
-// When compiling packages, build ignores files that end in '_test.go'.
-//
 // The -o flag forces build to write the resulting executable or object
 // to the named output file or directory, instead of the default behavior described
 // in the last two paragraphs. If the named output is a directory that exists,
index ed5a149da355f82fb4e0d6219b8b3c11f19ca255..9305b2d859c549356f1e0739aeb2d9e7e29bc4e3 100644 (file)
@@ -30,6 +30,8 @@ along with their dependencies, but it does not install the results.
 If the arguments to build are a list of .go files from a single directory,
 build treats them as a list of source files specifying a single package.
 
+When compiling packages, build ignores files that end in '_test.go'.
+
 When compiling a single main package, build writes
 the resulting executable to an output file named after
 the first source file ('go build ed.go rx.go' writes 'ed' or 'ed.exe')
@@ -40,8 +42,6 @@ When compiling multiple packages or a single non-main package,
 build compiles the packages but discards the resulting object,
 serving only as a check that the packages can be built.
 
-When compiling packages, build ignores files that end in '_test.go'.
-
 The -o flag forces build to write the resulting executable or object
 to the named output file or directory, instead of the default behavior described
 in the last two paragraphs. If the named output is a directory that exists,