mirror of
https://github.com/prometheus/prometheus.git
synced 2025-02-21 03:16:00 -08:00
github action: Add buf-lint, fix buf (#10307)
* github action: Add buf-lint, fix buf Signed-off-by: Julien Pivotto <roidelapluie@inuits.eu>
This commit is contained in:
parent
aa8874bc56
commit
e239e3ee8b
20
.github/workflows/buf-lint.yml
vendored
Normal file
20
.github/workflows/buf-lint.yml
vendored
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
name: buf.build
|
||||||
|
on:
|
||||||
|
pull_request:
|
||||||
|
paths:
|
||||||
|
- ".github/workflows/buf-lint.yml"
|
||||||
|
- "**.proto"
|
||||||
|
jobs:
|
||||||
|
buf:
|
||||||
|
name: lint
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- uses: bufbuild/buf-setup-action@v0.6.0
|
||||||
|
- uses: bufbuild/buf-lint-action@v1
|
||||||
|
with:
|
||||||
|
input: 'prompb'
|
||||||
|
- uses: bufbuild/buf-breaking-action@v1
|
||||||
|
with:
|
||||||
|
input: 'prompb'
|
||||||
|
against: 'https://github.com/prometheus/prometheus.git#branch=main,ref=HEAD,subdir=prompb'
|
5
.github/workflows/buf.yml
vendored
5
.github/workflows/buf.yml
vendored
|
@ -1,9 +1,12 @@
|
||||||
|
name: buf.build
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
|
buf:
|
||||||
|
name: lint and publish
|
||||||
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- uses: bufbuild/buf-setup-action@v0.6.0
|
- uses: bufbuild/buf-setup-action@v0.6.0
|
||||||
|
|
|
@ -1,4 +1,18 @@
|
||||||
version: v1
|
version: v1
|
||||||
name: buf.build/prometheus/prometheus
|
name: buf.build/prometheus/prometheus
|
||||||
|
lint:
|
||||||
|
ignore_only:
|
||||||
|
ENUM_VALUE_PREFIX:
|
||||||
|
- remote.proto
|
||||||
|
- types.proto
|
||||||
|
ENUM_ZERO_VALUE_SUFFIX:
|
||||||
|
- remote.proto
|
||||||
|
- types.proto
|
||||||
|
PACKAGE_DIRECTORY_MATCH:
|
||||||
|
- remote.proto
|
||||||
|
- types.proto
|
||||||
|
PACKAGE_VERSION_SUFFIX:
|
||||||
|
- remote.proto
|
||||||
|
- types.proto
|
||||||
deps:
|
deps:
|
||||||
- buf.build/gogo/protobuf
|
- buf.build/gogo/protobuf
|
||||||
|
|
Loading…
Reference in a new issue