protos

module
v2.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 26, 2021 License: MIT

README

protos

protos defines shared proto pkg for all protomicro golang repos.

protoc installation

Download protoc from https://github.com/protocolbuffers/protobuf/releases Copy BOTH protoc file and include folder to ${GOPATH}/bin/protoc.

Or you can use apt on Linux, brew on Mac.

go install google.golang.org/grpc/cmd/protoc-gen-go-grpc

Step by step

Protobuf generation

protos - Generate protobuf, grpc-gateway files:

make protos

faker - Generate faker tags in pb files for testing:

make faker

Usage

To use protos in another repo, execute go get github.com/gomaglev/protos to update go.mod.

To use specific branch execute go get github.com/gomaglev/protos@{commit hash}

Troubleshooting

google/protobuf/timestamp.proto: File not found. make sure the include folder in protoc release package was copied to same folder as protoc.

Directories

Path Synopsis
pkg

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL