Skip to content

Commit 7782c89

Browse files
authored
[skip-changelog] Small improvements in Taskfile about protocol buffer generation (#2793)
* Do not run protoc tasks in parallel Otherwise if the format task changes the underlying files, it will make fail the other tasks. task: [protoc:breaking-change-detection] buf breaking --against '.git#branch=origin/master,subdir=rpc' task: [protoc:format] buf format --write --exit-code task: [protoc:check] buf lint task: [protoc:compile] buf dep update Failure: context canceled Failure: context canceled Failure: context canceled exit status 100 * Simplified taskfile * Do not exit with error if `buf format` formats a file This is the intended behaviour.
1 parent 0a116e7 commit 7782c89

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

Diff for: Taskfile.yml

+7-8
Original file line numberDiff line numberDiff line change
@@ -228,11 +228,11 @@ tasks:
228228

229229
protoc:
230230
desc: Lint, format and compile protobuf definitions
231-
deps:
232-
- protoc:check
233-
- protoc:format
234-
- protoc:compile
235-
- protoc:breaking-change-detection
231+
cmds:
232+
- task: protoc:format
233+
- task: protoc:check
234+
- task: protoc:compile
235+
- task: protoc:breaking-change-detection
236236

237237
protoc:compile:
238238
desc: Compile protobuf definitions
@@ -243,8 +243,7 @@ tasks:
243243
protoc:docs:
244244
desc: Generate docs for protobuf definitions
245245
cmds:
246-
- |
247-
buf generate --template buf.doc.gen.yaml
246+
- buf generate --template buf.doc.gen.yaml
248247

249248
docs:include-configuration-json-schema:
250249
desc: Copy configuration JSON schema to make it available in documentation
@@ -266,7 +265,7 @@ tasks:
266265
protoc:format:
267266
desc: Perform formatting of the protobuf definitions
268267
cmds:
269-
- buf format --write --exit-code
268+
- buf format --write
270269

271270
protoc:breaking-change-detection:
272271
desc: Detect protobuf breaking changes

0 commit comments

Comments
 (0)