From f801f3f174f2c39b2b3780796e1c58891c5e8c3e Mon Sep 17 00:00:00 2001 From: Christoph Blecker Date: Thu, 25 Jan 2018 13:30:30 -0800 Subject: [PATCH] Change flags to variables so that they can be passed through make --- build/root/Makefile | 2 +- hack/make-rules/verify.sh | 23 ++++------------------- 2 files changed, 5 insertions(+), 20 deletions(-) diff --git a/build/root/Makefile b/build/root/Makefile index 2ea2bce0ce433..ab323776d7276 100644 --- a/build/root/Makefile +++ b/build/root/Makefile @@ -123,7 +123,7 @@ verify: @echo "$$VERIFY_HELP_INFO" else verify: verify_generated_files - KUBE_VERIFY_GIT_BRANCH=$(BRANCH) hack/make-rules/verify.sh -v + KUBE_VERIFY_GIT_BRANCH=$(BRANCH) hack/make-rules/verify.sh endif define QUICK_VERIFY_HELP_INFO diff --git a/hack/make-rules/verify.sh b/hack/make-rules/verify.sh index ece3916870edc..1af7f2cfff0e5 100755 --- a/hack/make-rules/verify.sh +++ b/hack/make-rules/verify.sh @@ -129,30 +129,15 @@ function run-checks { done } -SILENT=true -QUICK=false - -while getopts ":vQ" opt; do - case ${opt} in - v) - SILENT=false - ;; - Q) - QUICK=true - ;; - \?) - echo "Invalid flag: -${OPTARG}" >&2 - exit 1 - ;; - esac -done +SILENT=${SILENT:-false} +QUICK=${QUICK:-false} if ${SILENT} ; then - echo "Running in silent mode, run with -v if you want to see script logs." + echo "Running in silent mode, run with SILENT=false if you want to see script logs." fi if ${QUICK} ; then - echo "Running in quick mode (-Q flag). Only fast checks will run." + echo "Running in quick mode (QUICK=true). Only fast checks will run." fi ret=0