From f6a2915f2691f1dc65e598a453f783d1c58993c7 Mon Sep 17 00:00:00 2001 From: "Dr. Stefan Schimanski" Date: Thu, 16 Feb 2017 10:51:29 +0100 Subject: [PATCH] hack/*.sh: re-add staging dirs to verify+update scripts --- hack/update-gofmt.sh | 3 +-- hack/verify-gofmt.sh | 2 +- hack/verify-pkg-names.sh | 2 +- hack/verify-readonly-packages.sh | 3 ++- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/hack/update-gofmt.sh b/hack/update-gofmt.sh index c71fe71a02..83800c6eee 100755 --- a/hack/update-gofmt.sh +++ b/hack/update-gofmt.sh @@ -34,11 +34,10 @@ find_files() { -o -wholename './_output' \ -o -wholename './_gopath' \ -o -wholename './release' \ - -o -wholename './staging' \ -o -wholename './target' \ -o -wholename '*/third_party/*' \ -o -wholename '*/vendor/*' \ - -o -wholename './staging' \ + -o -wholename './staging/src/k8s.io/client-go/*vendor/*' \ \) -prune \ \) -name '*.go' } diff --git a/hack/verify-gofmt.sh b/hack/verify-gofmt.sh index ee6e420ec2..af1b50675c 100755 --- a/hack/verify-gofmt.sh +++ b/hack/verify-gofmt.sh @@ -42,7 +42,7 @@ find_files() { -o -wholename './target' \ -o -wholename '*/third_party/*' \ -o -wholename '*/vendor/*' \ - -o -wholename './staging' \ + -o -wholename './staging/src/k8s.io/client-go/*vendor/*' \ -o -wholename '*/bindata.go' \ \) -prune \ \) -name '*.go' diff --git a/hack/verify-pkg-names.sh b/hack/verify-pkg-names.sh index 75fda42536..79bb85f684 100755 --- a/hack/verify-pkg-names.sh +++ b/hack/verify-pkg-names.sh @@ -26,7 +26,7 @@ source "${KUBE_ROOT}/hack/lib/init.sh" kube::golang::verify_go_version cd "${KUBE_ROOT}" -if git --no-pager grep -E $'^(import |\t)[a-z]+[A-Z_][a-zA-Z]* "[^"]+"$' -- '**/*.go' ':(exclude)vendor/*' ':(exclude)staging/*'; then +if git --no-pager grep -E $'^(import |\t)[a-z]+[A-Z_][a-zA-Z]* "[^"]+"$' -- '**/*.go' ':(exclude)vendor/*' ':(exclude)staging/src/k8s.io/client-go/*vendor/*'; then echo "!!! Some package aliases break go conventions." echo "To fix these errors, do not use capitalized or underlined characters" echo "in pkg aliases. Refer to https://blog.golang.org/package-names for more info." diff --git a/hack/verify-readonly-packages.sh b/hack/verify-readonly-packages.sh index 92d078b126..babf558e80 100755 --- a/hack/verify-readonly-packages.sh +++ b/hack/verify-readonly-packages.sh @@ -37,7 +37,8 @@ find_files() { -o -wholename './target' \ -o -wholename '*/third_party/*' \ -o -wholename '*/vendor/*' \ - -o -wholename './staging' \ + -o -wholename './staging/src/k8s.io/client-go/*vendor/*' \ + -o -wholename './staging/src/k8s.io/client-go/pkg/*' \ \) -prune \ \) -name '.readonly' }