Skip to content

rsbh/buf-lint-action

 
 

Repository files navigation

buf-lint-action

Lint Protobuf files with buf, and comment in-line on pull requests.

image

Usage

Refer to the action.yml to see all of the action parameters.

The buf-lint action requires that buf is installed in the Github Action runner, so we'll use the buf-setup action to install it.

Basic

In most cases, all you'll need to do is configure buf-setup to setup the buf binary for your action.

steps:
  - uses: actions/checkout@v2
  - uses: bufbuild/buf-setup-action@v0.5.0
  - uses: bufbuild/buf-lint-action@v1

Inputs

Some repositories are structured so that their buf.yaml is defined in a sub-directory alongside their Protobuf sources, such as a proto/ directory. In this case, you can specify the relative input path.

$ tree
.
└── proto
    ├── acme
    │   └── weather
    │       └── v1
    │           └── weather.proto
    └── buf.yaml
steps:
  - uses: actions/checkout@v2
  - uses: bufbuild/buf-setup-action@v0.5.0
  - uses: bufbuild/buf-lint-action@v1
    with:
      input: 'proto'

The buf-lint action is also commonly used alongside other buf actions, such as buf-breaking and buf-push.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • TypeScript 86.1%
  • JavaScript 12.2%
  • Makefile 1.7%