Skip to content

Commit

Permalink
Fix the gen-check target. (istio#316)
Browse files Browse the repository at this point in the history
  • Loading branch information
geeknoid authored and istio-testing committed Oct 3, 2019
1 parent 4ca1b68 commit 70a3598
Show file tree
Hide file tree
Showing 9 changed files with 492 additions and 1,128 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ TARGET_OUT ?= $(HOME)/istio_out/$(REPO_NAME)
ifeq ($(BUILD_WITH_CONTAINER),1)
CONTAINER_CLI ?= docker
DOCKER_SOCKET_MOUNT ?= -v /var/run/docker.sock:/var/run/docker.sock
IMG ?= gcr.io/istio-testing/build-tools:2019-10-02T14-57-08
IMG ?= gcr.io/istio-testing/build-tools:2019-10-02T16-55-19
UID = $(shell id -u)
PWD = $(shell pwd)

Expand Down
11 changes: 8 additions & 3 deletions Makefile.core.mk
Original file line number Diff line number Diff line change
Expand Up @@ -43,12 +43,15 @@ update-charts: installer.sha
vfsgen: data/ update-charts
go generate ./...

clean-vfs:
@rm -fr pkg/vfs/assets.gen.go

gen: generate-values generate-types vfsgen
generate: gen

gen-check: clean gen check-clean-repo

clean: clean-values clean-types
clean: clean-values clean-types clean-vfs

default: mesh

Expand Down Expand Up @@ -87,8 +90,10 @@ types_v1alpha2_openapi := $(types_v1alpha2_protos:.proto=.json)
$(types_v1alpha2_pb_gos) $(types_v1alpha2_pb_docs) $(types_v1alpha2_pb_pythons): $(types_v1alpha2_protos)
@$(protoc) $(go_plugin) $(protoc_gen_docs_plugin)$(types_v1alpha2_path) $(protoc_gen_python_plugin) $^
@cp -r ${TMPDIR}/pkg/* pkg/
@sed -i -e 's|github.com/gogo/protobuf/protobuf/google/protobuf|github.com/gogo/protobuf/types|g' $(types_v1alpha2_path)/istiocontrolplane_types.pb.go
@sed -i 's|github.com/gogo/protobuf/protobuf/google/protobuf|github.com/gogo/protobuf/types|g' $(types_v1alpha2_path)/istiocontrolplane_types.pb.go
@go run $(repo_dir)/pkg/apis/istio/fixup_structs/main.go -f $(types_v1alpha2_path)/istiocontrolplane_types.pb.go
@sed -i 's|<key,value,effect>|\&lt\;key,value,effect\&gt\;|g' $(types_v1alpha2_path)/v1alpha2.pb.html
@sed -i 's|<operator>|\&lt\;operator\&gt\;|g' $(types_v1alpha2_path)/v1alpha2.pb.html

generate-types: $(types_v1alpha2_pb_gos) $(types_v1alpha2_pb_docs) $(types_v1alpha2_pb_pythons)

Expand All @@ -105,7 +110,7 @@ values_v1alpha1_openapi := $(values_v1alpha1_protos:.proto=.json)
$(values_v1alpha1_pb_gos) $(values_v1alpha1_pb_docs) $(values_v1alpha1_pb_pythons): $(values_v1alpha1_protos)
@$(protoc) $(go_plugin) $(protoc_gen_docs_plugin)$(values_v1alpha1_path) $(protoc_gen_python_plugin) $^
@cp -r ${TMPDIR}/pkg/* pkg/
@sed -i -e 's|github.com/gogo/protobuf/protobuf/google/protobuf|github.com/gogo/protobuf/types|g' $(values_v1alpha1_path)/values_types.pb.go
@sed -i 's|github.com/gogo/protobuf/protobuf/google/protobuf|github.com/gogo/protobuf/types|g' $(values_v1alpha1_path)/values_types.pb.go
@GOARCH=amd64 GOOS=linux go run $(repo_dir)/pkg/apis/istio/fixup_structs/main.go -f $(values_v1alpha1_path)/values_types.pb.go

generate-values: $(values_v1alpha1_pb_gos) $(values_v1alpha1_pb_docs) $(values_v1alpha1_pb_pythons)
Expand Down
2 changes: 1 addition & 1 deletion common-protos/.commonfiles.sha
Original file line number Diff line number Diff line change
@@ -1 +1 @@
38d0ef1555bc5f1079e4a439b5c771565b4df03b
c55dbd8338d5806b056e071580d58348dee999e2
2 changes: 1 addition & 1 deletion common/.commonfiles.sha
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3bbdd1b79a068217be7ca2e3a7b7b5b7a3cc1d96
c55dbd8338d5806b056e071580d58348dee999e2
2 changes: 1 addition & 1 deletion common/Makefile.common.mk
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,6 @@ update-common-protos:
@rm -fr common-files

check-clean-repo:
@scripts/check_clean_repo.sh
@common/scripts/check_clean_repo.sh

.PHONY: lint-dockerfiles lint-scripts lint-yaml lint-copyright-banner lint-go lint-python lint-helm lint-markdown lint-sass lint-typescript lint-protos lint-all format-go format-python format-protos update-common update-common-protos lint-licenses dump-licenses dump-licenses-csv check-clean-repo
4 changes: 2 additions & 2 deletions pkg/apis/istio/v1alpha1/v1alpha1.pb.html

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

2 changes: 1 addition & 1 deletion pkg/apis/istio/v1alpha1/values_types.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 pkg/apis/istio/v1alpha1/values_types.proto
Original file line number Diff line number Diff line change
Expand Up @@ -450,7 +450,7 @@ message GlobalConfig {

// GlobalLoggingConfig specifies the global logging level settings for the Istio control plane components.
message GlobalLoggingConfig {
// Comma-separated minimum per-scope logging level of messages to output, in the form of <scope>:<level>,<scope>:<level>
// Comma-separated minimum per-scope logging level of messages to output, in the form of `<scope>:<level>,<scope>:<level>`
// The control plane has different scopes depending on component, but can configure default log level across all components
// If empty, default scope and level will be used as configured in code
string level = 1;
Expand Down
Loading

0 comments on commit 70a3598

Please sign in to comment.