From 4ad6ae83ae78c9127e862e6cccb568ec6902b025 Mon Sep 17 00:00:00 2001 From: ZhiFeng1993 Date: Tue, 26 May 2020 21:49:38 -0700 Subject: [PATCH] Add usage in some hack/update scripts --- hack/update-generated-pod-resources.sh | 5 +++++ hack/update-generated-protobuf-dockerized.sh | 5 +++++ hack/update-generated-protobuf.sh | 3 +++ hack/update-generated-runtime-dockerized.sh | 3 +++ hack/update-generated-runtime.sh | 5 +++++ hack/update-generated-swagger-docs.sh | 2 +- 6 files changed, 22 insertions(+), 1 deletion(-) diff --git a/hack/update-generated-pod-resources.sh b/hack/update-generated-pod-resources.sh index 6fa2b1d4465..d6257a3222c 100755 --- a/hack/update-generated-pod-resources.sh +++ b/hack/update-generated-pod-resources.sh @@ -14,6 +14,11 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script generates `/pkg/kubelet/apis/podresources/v1alpha1/api.pb.go` +# from the protobuf file `/pkg/kubelet/apis/podresources/v1alpha1/api.proto` +# for pods. +# Usage: `hack/update-generated-pod-resources.sh`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/update-generated-protobuf-dockerized.sh b/hack/update-generated-protobuf-dockerized.sh index b7bc5a66376..d4f72988e17 100755 --- a/hack/update-generated-protobuf-dockerized.sh +++ b/hack/update-generated-protobuf-dockerized.sh @@ -14,6 +14,11 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script genertates `*/api.pb.go` from the protobuf file `*/api.proto`. +# Usage: +# hack/update-generated-protobuf-dockerized.sh "${APIROOTS}" +# An example APIROOT is: "k8s.io/api/admissionregistration/v1" + set -o errexit set -o nounset set -o pipefail diff --git a/hack/update-generated-protobuf.sh b/hack/update-generated-protobuf.sh index 1a04aa1d52a..01b826ab2a0 100755 --- a/hack/update-generated-protobuf.sh +++ b/hack/update-generated-protobuf.sh @@ -14,6 +14,9 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script generates all go files from the corresponding protobuf files. +# Usage: `hack/update-generated-protobuf.sh`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/update-generated-runtime-dockerized.sh b/hack/update-generated-runtime-dockerized.sh index 8e17dade6ba..a977bb16cdb 100755 --- a/hack/update-generated-runtime-dockerized.sh +++ b/hack/update-generated-runtime-dockerized.sh @@ -14,6 +14,9 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script builds protoc-gen-gogo binary in runtime and genertates +# `*/api.pb.go` from the protobuf file `*/api.proto`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/update-generated-runtime.sh b/hack/update-generated-runtime.sh index a2261f45f09..a2656daea98 100755 --- a/hack/update-generated-runtime.sh +++ b/hack/update-generated-runtime.sh @@ -14,6 +14,11 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script builds protoc-gen-gogo binary in runtime and genertates +# `*/api.pb.go` from the protobuf file `*/api.proto`. +# Usage: +# hack/update-generated-runtime.sh + set -o errexit set -o nounset set -o pipefail diff --git a/hack/update-generated-swagger-docs.sh b/hack/update-generated-swagger-docs.sh index 1711be103b2..90b21f28fec 100755 --- a/hack/update-generated-swagger-docs.sh +++ b/hack/update-generated-swagger-docs.sh @@ -14,7 +14,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -# Generates `types_swagger_doc_generated.go` files for API group +# This script generates `types_swagger_doc_generated.go` files for API group # versions. That file contains functions on API structs that return # the comments that should be surfaced for the corresponding API type # in our API docs.