Go Tool Shared Flags: Difference between revisions
(26 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
=Internal= | =Internal= | ||
* [[Go_Tool#Shared_Flags|<tt>go</tt> Tool]] | |||
=Overview= | |||
These flags are shared by the <code>[[Go_Tool#build|build]]</code>, <code>[[Go_Tool#clean|clean]]</code>, <code>[[Go_Tool#get|get]]</code>, <code>[[Go_Tool#install|install]]</code>, <code>[[Go_Tool#list|list]]</code>, <code>[[Go_Tool#run|run]]</code>, and <code>[[Go_Tool#test|test]]</code> commands. | |||
=<tt>-v</tt>= | |||
Print the names of packages as they are compiled. | |||
=<tt>-x</tt>= | |||
Print the commands while running them. | |||
=<tt>-a</tt>= | =<tt>-a</tt>= | ||
Line 14: | Line 19: | ||
Print the commands but do not run them. | Print the commands but do not run them. | ||
=<tt>-work</tt>= | |||
Print the name of the temporary work directory and do not delete it when exiting. | |||
=<tt>-p</tt>= | =<tt>-p</tt>= | ||
Line 30: | Line 38: | ||
Enable interoperation with memory sanitizer. Supported only on linux/amd64, and only with Clang/LLVM as the host C compiler. | Enable interoperation with memory sanitizer. Supported only on linux/amd64, and only with Clang/LLVM as the host C compiler. | ||
Latest revision as of 00:29, 3 October 2023
Internal
Overview
These flags are shared by the build
, clean
, get
, install
, list
, run
, and test
commands.
-v
Print the names of packages as they are compiled.
-x
Print the commands while running them.
-a
Force rebuilding of packages that are already up-to-date.
-n
Print the commands but do not run them.
-work
Print the name of the temporary work directory and do not delete it when exiting.
-p
-p n
represents the number of programs, such as build commands or test binaries, that can be run in parallel. The default is the number of CPUs available, except on darwin/arm which defaults to 1.
-race
Enable data race detection. Supported only on linux/amd64, freebsd/amd64, darwin/amd64 and windows/amd64.
-msan
Enable interoperation with memory sanitizer. Supported only on linux/amd64, and only with Clang/LLVM as the host C compiler.