Skip to content

Commit

Permalink
Remove all gogoproto extensions
Browse files Browse the repository at this point in the history
This commit removes the following gogoproto extensions;

- gogoproto.nullable
- gogoproto.customename
- gogoproto.unmarshaller_all
- gogoproto.stringer_all
- gogoproto.sizer_all
- gogoproto.marshaler_all
- gogoproto.goproto_unregonized_all
- gogoproto.goproto_stringer_all
- gogoproto.goproto_getters_all

None of them are supported by Google's toolchain (see containerd#6564).

Signed-off-by: Kazuyoshi Kato <[email protected]>
  • Loading branch information
kzys authored and Kirtana Ashok committed Jan 18, 2023
1 parent c7a8599 commit d363ed7
Show file tree
Hide file tree
Showing 48 changed files with 1,301 additions and 1,246 deletions.
3 changes: 1 addition & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,7 @@ protos: bin/protoc-gen-gogoctrd ## generate protobuf
@(PATH="${ROOTDIR}/bin:${PATH}" protobuild --quiet ${NON_API_PACKAGES})
@mv ${TMPDIR}/vendor ${ROOTDIR}
@rm -rf ${TMPDIR}
go-fix-acronym -w -a '(Io|Uuid|Os)$$' $(shell find api -name '*.pb.go')

check-protos: protos ## check if protobufs needs to be generated again
@echo "$(WHALE) $@"
Expand All @@ -185,8 +186,6 @@ proto-fmt: ## check format of proto files
@echo "$(WHALE) $@"
@test -z "$$(find . -path ./vendor -prune -o -path ./protobuf/google/rpc -prune -o -name '*.proto' -type f -exec grep -Hn -e "^ " {} \; | tee /dev/stderr)" || \
(echo "$(ONI) please indent proto files with tabs only" && false)
@test -z "$$(find . -path ./vendor -prune -o -name '*.proto' -type f -exec grep -Hn "Meta meta = " {} \; | grep -v '(gogoproto.nullable) = false' | tee /dev/stderr)" || \
(echo "$(ONI) meta fields in proto files must have option (gogoproto.nullable) = false" && false)

build: ## build the go packages
@echo "$(WHALE) $@"
Expand Down
84 changes: 42 additions & 42 deletions api/events/task.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion api/events/task.proto
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ message TaskCreate {
string container_id = 1;
string bundle = 2;
repeated containerd.types.Mount rootfs = 3;
TaskIO io = 4 [(gogoproto.customname) = "IO"];
TaskIO io = 4;
string checkpoint = 5;
uint32 pid = 6;
}
Expand Down
Loading

0 comments on commit d363ed7

Please sign in to comment.