docs: format markdown and add go mod in demo (#155)

master
maiyang 4 years ago committed by GitHub
parent cf33aae91d
commit 91bfc093f4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -164,6 +164,8 @@ go get -u github.com/tal-tech/go-zero
```shell ```shell
cd greet cd greet
go mod init
go mod tidy
go run greet.go -f etc/greet-api.yaml go run greet.go -f etc/greet-api.yaml
``` ```

@ -108,6 +108,8 @@ GO111MODULE=on GOPROXY=https://goproxy.cn/,direct go get -u github.com/tal-tech/
```shell ```shell
goctl api new greet goctl api new greet
cd greet cd greet
go mod init
go mod tidy
go run greet.go -f etc/greet-api.yaml go run greet.go -f etc/greet-api.yaml
``` ```
@ -121,8 +123,11 @@ GO111MODULE=on GOPROXY=https://goproxy.cn/,direct go get -u github.com/tal-tech/
```http ```http
HTTP/1.1 200 OK HTTP/1.1 200 OK
Date: Sun, 30 Aug 2020 15:32:35 GMT Content-Type: application/json
Content-Length: 0 Date: Thu, 22 Oct 2020 14:03:18 GMT
Content-Length: 14
{"message":""}
``` ```
编写业务代码: 编写业务代码:

Loading…
Cancel
Save