An open API service indexing awesome lists of open source software.

https://github.com/nlm/protoc-gen-demo

Demo of how to make a protoc generator in Go
https://github.com/nlm/protoc-gen-demo

Last synced: 5 months ago
JSON representation

Demo of how to make a protoc generator in Go

Awesome Lists containing this project

README

          

# protoc-gen-demo

a demo on how to make a minimal protobuf code generator

## how to use

Build the generator

```bash
$ make build
go build -o protoc-gen-demo main.go
```

Use it with protoc

```bash
$ make demo
protoc --demo_out=demo --plugin protoc-gen-demo=protoc-gen-demo demo/demo.proto
go run ./cmd/demo
Hello, Demo!
```