Ginny base on gRPC + gRPC-Gateway, more components to improve development efficiency.
cd $GOPATH && go get github.com/goriller/ginny-cli/ginny- protoc
https://github.com/protocolbuffers/protobuf/releases
- protoc-gen-go:
cd $GOPATH && go install github.com/golang/protobuf/protoc-gen-go@latest- go wire:
cd $GOPATH && go get github.com/google/wire/cmd/wire- protoc-gen-validate:
cd $GOPATH && go install github.com/envoyproxy/protoc-gen-validate@latest- goimports:
cd $GOPATH && go get golang.org/x/tools/cmd/goimports- mockgen:
cd $GOPATH && go install github.com/golang/mock/mockgen@v1.6.0- make:
Mac OS and Linux systems already have the make command,
windows: How to run "make" command in gitbash in windows?
ginny new hellodemomake protoc// wire
make wireif you use vscode , edit the .vscode/launch.json , like this:
{
"version": "0.2.0",
"configurations": [
{
"name": "Launch GoPackage",
"type": "go",
"request": "launch",
"mode": "auto",
"program": "${workspaceFolder}/cmd",
"env": {
// ...
},
"args": [
"-conf","../configs/dev.yml"
// "-remote", "etcd://127.0.0.1:1233/test",
]
}
]
}
Select Launch GoPackage to debug run. Try to call http://localhost:8080/ or grpc://127.0.0.1:9000/ .
Check out the quick start example.