mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-21 10:51:29 +00:00
fix hack/make-rules/make-help.sh shellcheck failures
This commit is contained in:
parent
1215aa73d2
commit
0fad8eb36c
@ -21,7 +21,6 @@
|
||||
./hack/lib/swagger.sh
|
||||
./hack/lib/test.sh
|
||||
./hack/lib/version.sh
|
||||
./hack/make-rules/make-help.sh
|
||||
./hack/test-integration.sh
|
||||
./hack/verify-test-featuregates.sh
|
||||
./test/cmd/diff.sh
|
||||
|
@ -21,22 +21,21 @@ set -o pipefail
|
||||
readonly red=$(tput setaf 1)
|
||||
readonly reset=$(tput sgr0)
|
||||
|
||||
KUBE_ROOT=$(dirname "${BASH_SOURCE}")/../..
|
||||
KUBE_ROOT=$(dirname "${BASH_SOURCE[0]}")/../..
|
||||
ALL_TARGETS=$(make -C "${KUBE_ROOT}" PRINT_HELP=y -rpn | sed -n -e '/^$/ { n ; /^[^ .#][^ ]*:/ { s/:.*$// ; p ; } ; }' | sort)
|
||||
CMD_TARGETS=$(ls -l "${KUBE_ROOT}/cmd" |awk '/^d/ {print $NF}')
|
||||
CMD_TARGETS=$(cd "${KUBE_ROOT}/cmd"; find . -type d -mindepth 1 -maxdepth 1 | cut -c 3-)
|
||||
CMD_FLAG=false
|
||||
PLUGIN_CMD_FLAG=false
|
||||
|
||||
echo "--------------------------------------------------------------------------------"
|
||||
for tar in ${ALL_TARGETS}; do
|
||||
for cmdtar in ${CMD_TARGETS}; do
|
||||
if [ ${tar} = ${cmdtar} ]; then
|
||||
if [ "${tar}" = "${cmdtar}" ]; then
|
||||
if [ ${CMD_FLAG} = true ]; then
|
||||
continue 2;
|
||||
fi
|
||||
|
||||
echo -e "${red}${CMD_TARGETS}${reset}"
|
||||
make -C "${KUBE_ROOT}" ${tar} PRINT_HELP=y
|
||||
make -C "${KUBE_ROOT}" "${tar}" PRINT_HELP=y
|
||||
echo "---------------------------------------------------------------------------------"
|
||||
|
||||
CMD_FLAG=true
|
||||
@ -45,6 +44,6 @@ for tar in ${ALL_TARGETS}; do
|
||||
done
|
||||
|
||||
echo -e "${red}${tar}${reset}"
|
||||
make -C "${KUBE_ROOT}" ${tar} PRINT_HELP=y
|
||||
make -C "${KUBE_ROOT}" "${tar}" PRINT_HELP=y
|
||||
echo "---------------------------------------------------------------------------------"
|
||||
done
|
||||
|
Loading…
Reference in New Issue
Block a user