The Buf CLI is a crucial tool for managing Protobuf schemas. This directory supplements its [documentation][documentation] with examples and quickstart code showing how to use its features for code generation, breaking change detection, and linting tasks.
Quickstart code for the Buf CLI's Quickstart introduces you to key features of the Buf CLI, including setting up a local workspace, generating code, breaking change detection, and linting. It contains a start directory with a starting state and finish directory with a working solution.
Quickstart code for the breaking change detection quickstart provides a walkthrough of using Buf's breaking change detection to ensure that your organization can evolve Protobuf schemas quickly and safely. It contains a start directory with a starting state and finish directory with a working solution.
Quickstart code for the lint quickstart provides a walkthrough of checking for lint errors, customizing your lint configuration, and temporarily ignoring errors. It contains a start directory with a starting state and finish directory with a working solution.
Example code for local plugin execution provides an example of code generation using local protoc plugins.
Example code for remote plugin execution provides an example of code generation using plugins hosted on the Buf Schema Registry (BSR).
Example code for generating code stubs using managed mode provides an example of controlling file and field options without adding language-specific options to Protobuf files.
Example code for the buf build command showing how to limit output types with --type.
Example code for the Buf CLI provides an example of using one buf.gen.yaml file to manage multiple modules of Protobuf files in one repository.