Skip to content
forked from anjmao/go2proto

Generate protobuf messages from go structs

License

Notifications You must be signed in to change notification settings

emarcey/go2proto

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

go2proto

Generate Protobuf messages from given go structs. No RPC, not gogo syntax, just pure Protobuf messages.

Forked from github.com/anjmao/go2proto

Example

GO111MODULE=off go get -u github.com/emarcey/go2proto
go2proto -f ./example/out -p github.com/emarcey/go2proto/example/in

Configuration

  • -f: directory of go files to convert to proto messages
  • -p: target directory for output proto
  • filter: if set, excludes all structs not containing this string
  • -c: current proto, path of existing version of proto to use for diff
  • -s: bool option, default false; if true, will use snake_case for field names instead of default camelCase