diff --git a/hack/verify-gofmt.sh b/hack/verify-gofmt.sh index af597e1cc96..03888f09f6c 100755 --- a/hack/verify-gofmt.sh +++ b/hack/verify-gofmt.sh @@ -14,7 +14,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -# GoFmt apparently is changing @ head... +# This script checks whether the source codes need to be formatted or not by +# `gofmt`. We should run `hack/update-gofmt.sh` if actually formats them. +# Usage: `hack/verify-gofmt.sh`. +# Note: GoFmt apparently is changing @ head... set -o errexit set -o nounset diff --git a/hack/verify-golint.sh b/hack/verify-golint.sh index 1b1f1bbac58..a42a118afd4 100755 --- a/hack/verify-golint.sh +++ b/hack/verify-golint.sh @@ -16,7 +16,7 @@ # This script checks coding style for go language files in each # Kubernetes package by golint. -# Usage: hack/verify-golint.sh +# Usage: `hack/verify-golint.sh`. set -o errexit set -o nounset diff --git a/hack/verify-govet.sh b/hack/verify-govet.sh index 28c19f58d5a..b200b35483d 100755 --- a/hack/verify-govet.sh +++ b/hack/verify-govet.sh @@ -14,7 +14,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -# This script is a vestigial redirection. Please do not add "real" logic. +# This script vets all *.go files by running `go vet`. It is equivalent to +# `make vet`. +# Usage: `hack/verify-govet.sh` or `make vet`. +# Note: This script is a vestigial redirection. Please do not add "real" logic. set -o errexit set -o nounset diff --git a/hack/verify-import-aliases.sh b/hack/verify-import-aliases.sh index a80a94a2973..d6228a88fa3 100755 --- a/hack/verify-import-aliases.sh +++ b/hack/verify-import-aliases.sh @@ -14,6 +14,10 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script verifies that all the imports have our preferred alias(es). The +# preferred aliases for imports are listed in `hack/.import-aliases`. +# Usage: `hack/verify-import-aliases.sh`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/verify-import-boss.sh b/hack/verify-import-boss.sh index cbd611c9800..e159916fd20 100755 --- a/hack/verify-import-boss.sh +++ b/hack/verify-import-boss.sh @@ -14,6 +14,11 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script checks import restrictions. The script looks for a file called +# `.import-restrictions` in each directory, then all imports of the package are +# checked against each "rule" in the file. +# Usage: `hack/verify-import-boss.sh`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/verify-imports.sh b/hack/verify-imports.sh index 40bbca4a45f..35a2e5caa69 100755 --- a/hack/verify-imports.sh +++ b/hack/verify-imports.sh @@ -14,6 +14,11 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script checks restricted packages are imported or not and outputs the +# result. Target directory's path and allowed packages against checking are +# listed in `staging/publishing/import-restrictions.yaml`. +# Usage: `hack/verify-imports.sh`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/verify-linkcheck.sh b/hack/verify-linkcheck.sh index e0315473d74..f4a2f032f85 100755 --- a/hack/verify-linkcheck.sh +++ b/hack/verify-linkcheck.sh @@ -17,7 +17,7 @@ # This script extracts the links from types.go and .md files in pkg/api/, # pkg/apis/ and docs/ directories, checks the status code of the response, and # output the list of invalid links. -# Usage: hack/verify-linkcheck.sh +# Usage: `hack/verify-linkcheck.sh`. set -o errexit set -o nounset diff --git a/hack/verify-no-vendor-cycles.sh b/hack/verify-no-vendor-cycles.sh index 8a00c205879..7841e7056b8 100755 --- a/hack/verify-no-vendor-cycles.sh +++ b/hack/verify-no-vendor-cycles.sh @@ -14,6 +14,10 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script checks whether packages under `vendor` directory have cyclic +# dependencies on `main` or `staging` repositories. +# Usage: `hack/verify-no-vendor-cycles.sh`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/verify-openapi-spec.sh b/hack/verify-openapi-spec.sh index 92d4ee883f2..1316d76dd86 100755 --- a/hack/verify-openapi-spec.sh +++ b/hack/verify-openapi-spec.sh @@ -14,6 +14,11 @@ # See the License for the specific language governing permissions and # limitations under the License. +# This script checks whether updating of OpenAPI specification is needed or not. +# We should run `hack/update-openapi-spec.sh` if OpenAPI specification is out of +# date. +# Usage: `hack/verify-openapi-spec.sh`. + set -o errexit set -o nounset set -o pipefail diff --git a/hack/verify-pkg-names.sh b/hack/verify-pkg-names.sh index 03c4f83fcb7..37b7750355d 100755 --- a/hack/verify-pkg-names.sh +++ b/hack/verify-pkg-names.sh @@ -14,7 +14,8 @@ # See the License for the specific language governing permissions and # limitations under the License. -# Verify whether codes follow golang convention. +# This script verifies whether codes follow golang convention. +# Usage: `hack/verify-pkg-names.sh`. set -o errexit set -o nounset diff --git a/hack/verify-readonly-packages.sh b/hack/verify-readonly-packages.sh index bb1979af6f6..4519d01890a 100755 --- a/hack/verify-readonly-packages.sh +++ b/hack/verify-readonly-packages.sh @@ -14,9 +14,10 @@ # See the License for the specific language governing permissions and # limitations under the License. -# verify-readonly-packages.sh checks whether between $KUBE_VERIFY_GIT_BRANCH and HEAD files -# in readonly directories were modified. A directory is readonly iff it contains a .readonly -# file. Being readonly DOES NOT apply recursively to subdirectories. +# This script checks whether between $KUBE_VERIFY_GIT_BRANCH and HEAD files in +# readonly directories were modified. A directory is readonly if it contains a +# .readonly file. Being readonly DOES NOT apply recursively to subdirectories. +# Usage: `hack/verify-readonly-packages.sh`. set -o errexit set -o nounset