Categorygithub.com/omnipeak/protoc-gen-markdown
repository
0.0.7
Repository: https://github.com/omnipeak/protoc-gen-markdown.git
Documentation: pkg.go.dev

# Packages

No description provided by the author

# README

protoc-gen-markdown - Generates markdown from proto files

protoc-gen-markdown is a plugin for protoc which generates GitHub-flavored markdown (GFM) from proto files.

By default, it will include validation defined by protovalidate.

It can also generate Mermaid diagrams via additional flags.

Usage

With buf

buf generate ./example/protos

With protoc directly

# Standard usage
protoc -I./example/protos/ \
  --markdown_out=paths=source_relative:./example/output/ \
  models/models.proto \
  service/service.proto

# Mermaid variant
protoc -I./example/protos/ \
  --markdown_out=mermaid=true,paths=source_relative:./example/output/ \
  models/models.proto \
  service/service.proto

# Exclude validation details
protoc -I./example/protos/ \
  --markdown_out=protovalidate=false,paths=source_relative:./example/output/ \
  models/models.proto \
  service/service.proto