diff --git a/hack/awker.sh b/hack/awker.sh deleted file mode 100755 index 570b8a9e1..000000000 --- a/hack/awker.sh +++ /dev/null @@ -1,17 +0,0 @@ -# Usage: -# ./hack/showDeps ./plugin -# ./hack/showDeps ./kustomize - -function showDeps { - echo "==== begin $1 ==================================" - find $1 -name "*.go" |\ - xargs grep \"sigs.k8s.io/kustomize/api/ |\ - sed 's|:\s"| |' |\ - sed 's|"$||' |\ - awk '{ printf "%60s %s\n", $2, $1 }' |\ - sed 's|sigs.k8s.io/kustomize/api/||' |\ - sort | uniq - echo "==== end $1 ==================================" -} - -showDeps $1 diff --git a/hack/whatApi.sh b/hack/whatApi.sh new file mode 100755 index 000000000..eb035d3a6 --- /dev/null +++ b/hack/whatApi.sh @@ -0,0 +1,20 @@ +# Report on use of API module. +# +# Usage: +# ./hack/whatApi.sh plugin +# ./hack/whatApi.sh kustomize + +function whatApi { + echo "==== begin $1 ==================================" + find $1 -name "*.go" |\ + xargs grep \"sigs.k8s.io/kustomize/api/ |\ + sed 's|:\s"|: dummy "|' |\ + sed 's|:\s\w\+\s"| |' |\ + sed 's|"$||' |\ + awk '{ printf "%60s %s\n", $2, $1 }' |\ + sed 's|sigs.k8s.io/kustomize/api/||' |\ + sort | uniq + echo "==== end $1 ==================================" +} + +whatApi $1