Skip to content

Commit e992ec0

Browse files
committed
Add comments in several hack/*.sh
1 parent d1dd6cb commit e992ec0

12 files changed

+40
-15
lines changed

hack/get-build.sh

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,11 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17+
# This script retrieves the specified version of the Kubernetes tar.gz file via
18+
# Google Cloud Storage.
19+
# Usage: `hack/get-build.sh <version number or publication>`.
20+
# Example: `./hack/get-build.sh release/latest`.
21+
1722
set -o errexit
1823
set -o nounset
1924
set -o pipefail

hack/ginkgo-e2e.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17+
# This script runs e2e tests on Google Cloud Platform.
18+
# Usage: `hack/ginkgo-e2e.sh`.
19+
1720
set -o errexit
1821
set -o nounset
1922
set -o pipefail

hack/grab-profiles.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,9 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17+
# This script grabs profiles from running components.
18+
# Usage: `hack/grab-profiles.sh`.
19+
1720
set -o errexit
1821
set -o nounset
1922
set -o pipefail

hack/install-etcd.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,9 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17-
# Convenience script to download and install etcd in third_party.
17+
# This script is convenience to download and install etcd in third_party.
1818
# Mostly just used by CI.
19+
# Usage: `hack/install-etcd.sh`.
1920

2021
set -o errexit
2122
set -o nounset

hack/lint-dependencies.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17+
# This script checks version dependencies of modules. It checks whether all
18+
# pinned versions of checked dependencies match their preferred version or not.
19+
# Usage: `hack/lint-dependencies.sh`.
20+
1721
set -o errexit
1822
set -o nounset
1923
set -o pipefail

hack/list-feature-tests.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17-
# A single script that lists all of the [Feature:.+] tests in our e2e suite.
17+
# This script lists all of the [Feature:.+] tests in our e2e suite.
18+
# Usage: `hack/list-feature-tests.sh`.
19+
1820
set -o errexit
1921
set -o nounset
2022
set -o pipefail

hack/local-up-cluster.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,11 @@
1616

1717
KUBE_ROOT=$(dirname "${BASH_SOURCE[0]}")/..
1818

19-
# This command builds and runs a local kubernetes cluster.
20-
# You may need to run this as root to allow kubelet to open docker's socket,
21-
# and to write the test CA in /var/run/kubernetes.
19+
# This script builds and runs a local kubernetes cluster. You may need to run
20+
# this as root to allow kubelet to open docker's socket, and to write the test
21+
# CA in /var/run/kubernetes.
22+
# Usage: `hack/local-up-cluster.sh`.
23+
2224
DOCKER_OPTS=${DOCKER_OPTS:-""}
2325
export DOCKER=(docker "${DOCKER_OPTS[@]}")
2426
DOCKER_ROOT=${DOCKER_ROOT:-""}

hack/pin-dependency.sh

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,9 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17-
# Usage:
18-
# hack/pin-dependency.sh $MODULE $SHA-OR-TAG
19-
#
20-
# Example:
21-
# hack/pin-dependency.sh github.com/docker/docker 501cb131a7b7
17+
# This script switches to the preferred version for specified module.
18+
# Usage: `hack/pin-dependency.sh $MODULE $SHA-OR-TAG`.
19+
# Example: `hack/pin-dependency.sh github.com/docker/docker 501cb131a7b7`.
2220

2321
set -o errexit
2422
set -o nounset

hack/print-workspace-status.sh

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,9 @@
1313
# See the License for the specific language governing permissions and
1414
# limitations under the License.
1515

16-
# This command is used by bazel as the workspace_status_command
17-
# to implement build stamping with git information.
16+
# This script is used by bazel as the workspace_status_command to implement
17+
# build stamping with git information.
18+
# Usage: `hack/print-workspace-status.sh`.
1819

1920
set -o errexit
2021
set -o nounset

hack/run-in-gopath.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,10 @@
1515
# limitations under the License.
1616

1717
# This script sets up a temporary Kubernetes GOPATH and runs an arbitrary
18-
# command under it. Go tooling requires that the current directory be under
18+
# command under it. Go tooling requires that the current directory be under
1919
# GOPATH or else it fails to find some things, such as the vendor directory for
2020
# the project.
21+
# Usage: `hack/run-in-gopath.sh <command>`.
2122

2223
set -o errexit
2324
set -o nounset

hack/test-go.sh

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,9 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17-
# This script is a vestigial redirection. Please do not add "real" logic.
17+
# This script runs all *_test.go files. It is equivalent to `make test`.
18+
# Usage: `hack/test-go.sh` or `make test`.
19+
# Note: This script is a vestigial redirection. Please do not add "real" logic.
1820

1921
set -o errexit
2022
set -o nounset

hack/test-integration.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,10 @@
1414
# See the License for the specific language governing permissions and
1515
# limitations under the License.
1616

17-
# This script is a vestigial redirection. Please do not add "real" logic.
17+
# This script has been replaced by `make test-integration`.
18+
# `make test-integration` runs all integration tests.
19+
# Usage: `make test-integration`.
20+
# Note: This script is a vestigial redirection. Please do not add "real" logic.
1821

1922
set -o errexit
2023
set -o nounset

0 commit comments

Comments
 (0)