From b0252096fe11ba92febe7d453e1ddaf0b740dc8c Mon Sep 17 00:00:00 2001 From: tiancaiamao Date: Tue, 25 Dec 2018 17:40:33 +0800 Subject: [PATCH 1/3] *: tiny update CONTRIBUTING.md --- CONTRIBUTING.md | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 3e23f56c60f38..e06485e45aee5 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -63,7 +63,25 @@ please [set one up](http://golang.org/doc/code.html). The version of GO should be **1.11** or above. -After installation, you'll need `GOPATH` defined, +After installation, there are two ways to build TiDB binary. + +#### For a quick taste + +The `GOPATH` is not necessary. + +``` +mkdir tmp +cd tmp +echo 'module tidb' > go.mod +GO111MODULE=on go get github.com/pingcap/tidb@c385cbdcca83eeed283139814a7ea149e3116e66 +GO111MODULE=on go build -o tidb-server github.com/pingcap/tidb/tidb-server +``` + +The `c385cbdcca83eeed283139814a7ea149e3116e66` could be changed to the other commit hash, try the latest commit hash [here](https://github.com/pingcap/tidb/commits/master). + +#### For development + +You'll need `GOPATH` defined, and `PATH` modified to access your Go binaries. A common setup is the following but you could always google a setup for your own flavor. From b8a96f754ffa3105aaae63d68f436b5c0d52fddb Mon Sep 17 00:00:00 2001 From: tiancaiamao Date: Wed, 26 Dec 2018 09:42:18 +0800 Subject: [PATCH 2/3] address comment --- CONTRIBUTING.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e06485e45aee5..09e30e3c84267 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -65,7 +65,7 @@ The version of GO should be **1.11** or above. After installation, there are two ways to build TiDB binary. -#### For a quick taste +#### A quick taste The `GOPATH` is not necessary. From 40410cff8c1e9834de31425185de02a36639a864 Mon Sep 17 00:00:00 2001 From: tiancaiamao Date: Thu, 27 Dec 2018 17:14:59 +0800 Subject: [PATCH 3/3] address comment --- CONTRIBUTING.md | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 09e30e3c84267..be04aa3c31ded 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -65,7 +65,7 @@ The version of GO should be **1.11** or above. After installation, there are two ways to build TiDB binary. -#### A quick taste +#### For a quick taste The `GOPATH` is not necessary. @@ -77,12 +77,11 @@ GO111MODULE=on go get github.com/pingcap/tidb@c385cbdcca83eeed283139814a7ea149e3 GO111MODULE=on go build -o tidb-server github.com/pingcap/tidb/tidb-server ``` -The `c385cbdcca83eeed283139814a7ea149e3116e66` could be changed to the other commit hash, try the latest commit hash [here](https://github.com/pingcap/tidb/commits/master). +The `c385cbdcca83eeed283139814a7ea149e3116e66` can be changed to any other commit hash. Try the latest commit hash [here](https://github.com/pingcap/tidb/commits/master). #### For development -You'll need `GOPATH` defined, -and `PATH` modified to access your Go binaries. +You'll need `GOPATH` defined, and `PATH` modified to access your Go binaries. A common setup is the following but you could always google a setup for your own flavor.