mirror of
https://github.com/adambard/learnxinyminutes-docs.git
synced 2025-04-27 07:33:57 +00:00
add go build tags
This commit is contained in:
parent
ef1ccd2b0f
commit
18b7969726
@ -30,6 +30,12 @@ Go comes with a good standard library and a sizeable community.
|
|||||||
/* Multi-
|
/* Multi-
|
||||||
line comment */
|
line comment */
|
||||||
|
|
||||||
|
/* A build tag is a line comment starting with // +build
|
||||||
|
and can be execute by go build -tags="foo bar" command.
|
||||||
|
Build tags are placed before the package clause near or at the top of the file
|
||||||
|
followed by a blank line or other line comments. */
|
||||||
|
// +build prod, dev, test
|
||||||
|
|
||||||
// A package clause starts every source file.
|
// A package clause starts every source file.
|
||||||
// Main is a special name declaring an executable rather than a library.
|
// Main is a special name declaring an executable rather than a library.
|
||||||
package main
|
package main
|
||||||
|
Loading…
Reference in New Issue
Block a user