Skip to content

Commit 66a5a53

Browse files
committed
Use Buf Schema Registry
1 parent 13053d0 commit 66a5a53

File tree

7 files changed

+2942
-2036
lines changed

7 files changed

+2942
-2036
lines changed

.cirrus.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,3 +160,40 @@ docker_builder:
160160
--tag ghcr.io/cirruslabs/cirrus-cli:$CIRRUS_TAG \
161161
--tag ghcr.io/cirruslabs/cirrus-cli:latest \
162162
.
163+
164+
task:
165+
name: Check for lacking "buf generate" invocation
166+
167+
container:
168+
image: bufbuild/buf
169+
170+
generate_script: buf generate
171+
check_script: git diff --exit-code
172+
173+
task:
174+
only_if: $CIRRUS_TAG != ''
175+
name: buf push (tagged)
176+
177+
container:
178+
image: bufbuild/buf
179+
180+
login_script: echo $BUF_TOKEN | buf registry login --username $BUF_LOGIN --token-stdin
181+
push_script: buf push --tag $CIRRUS_TAG
182+
183+
env:
184+
BUF_LOGIN: edigaryev
185+
BUF_TOKEN: ENCRYPTED[b52d145079b1e26201b3c1a69f32a28fd9f9176b4b7fca2af1d193296bb7d12f895b2f36871a5d873ca4b51cf3aff15f]
186+
187+
task:
188+
only_if: $CIRRUS_BRANCH != ''
189+
name: buf push (branch)
190+
191+
container:
192+
image: bufbuild/buf
193+
194+
login_script: echo $BUF_TOKEN | buf registry login --username $BUF_LOGIN --token-stdin
195+
push_script: buf push --branch $CIRRUS_BRANCH
196+
197+
env:
198+
BUF_LOGIN: edigaryev
199+
BUF_TOKEN: ENCRYPTED[b52d145079b1e26201b3c1a69f32a28fd9f9176b4b7fca2af1d193296bb7d12f895b2f36871a5d873ca4b51cf3aff15f]

0 commit comments

Comments
 (0)