Go 언어 웹 프로그래밍 철저 입문

C:\>go help version

usage: go version


Version prints the Go version, as reported by runtime.Version.


C:\>go help tool

usage: go tool [-n] command [args...]


Tool runs the go tool command identified by the arguments.

With no arguments it prints the list of known tools.


The -n flag causes tool to print the command that would be executed but not execute it.


For more about each tool command, see 'go tool command -h'.


C:\workspace\go>go help run


usage: go run [build flags] [-exec xprog] gofiles... [arguments...]


Run compiles and runs the main package comprising the named Go source files.

A Go source file is defined to be a file ending in a literal ".go" suffix.


By default, 'go run' runs the compiled binary directly: 'a.out arguments...'.

If the -exec flag is given, 'go run' invokes the binary using xprog: 'xprog a.out arguments...'.

If the -exec flag is not given, GOOS or GOARCH is different from the system default, and a program named go_$GOOS_$GOARCH_exec can be found on the current search path, 'go run' invokes the binary using that program, for example 'go_nacl_386_exec a.out arguments...'. This allows execution of cross-compiled programs when a simulator or other execution method is available.


For more about build flags, see 'go help build'.


See also: go build.

신간 소식 구독하기
뉴스레터에 가입하시고 이메일로 신간 소식을 받아 보세요.