From b0cc68425b65663c36328f1274baf665347d7359 Mon Sep 17 00:00:00 2001 From: Agniva De Sarker Date: Sat, 24 Sep 2016 21:33:48 +0530 Subject: [PATCH] go: add page (#1085) --- pages/common/go.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 pages/common/go.md diff --git a/pages/common/go.md b/pages/common/go.md new file mode 100644 index 000000000..68c0d95ad --- /dev/null +++ b/pages/common/go.md @@ -0,0 +1,23 @@ +# go + +> Tool for managing go source code. + +- Download and install a package, specified by its import path: + +`go get {{package_path}}` + +- Compile and run a source file (it has to contain a `main` package): + +`go run {{file}}.go` + +- Compile the package present in the current directory: + +`go build` + +- Execute all test cases of the current package (files have to end with `_test.go`): + +`go test` + +- Compile and install the current package: + +`go install`