mirror of https://github.com/k3s-io/k3s
[update-staging] convert package name in IDL
This commit converts the package names in the proto IDL in client-go. This allows third parties (and repositories in staging) who make use of types in client-go to generate proto IDL themselves properly.pull/6/head
parent
fb40658f9d
commit
64b5124595
|
@ -161,6 +161,9 @@ grep -Rl "\"${MAIN_REPO_FROM_SRC}" "${CLIENT_REPO_TEMP}" | \
|
|||
echo "rewrite proto names in proto.RegisterType"
|
||||
find "${CLIENT_REPO_TEMP}" -type f -name "generated.pb.go" -print0 | xargs -0 ${SED} -i "s/k8s\.io\.kubernetes/k8s.io.client-go/g"
|
||||
|
||||
echo "rewrite proto IDL package names"
|
||||
find "${CLIENT_REPO_TEMP}" -type f -name "generated.proto" -print0 | xargs -0 ${SED} -i "s/k8s\.io\.kubernetes/k8s.io.client_go/g"
|
||||
|
||||
# strip all generator tags from client-go
|
||||
find "${CLIENT_REPO_TEMP}" -type f -name "*.go" -print0 | xargs -0 ${SED} -i '/^\/\/ +k8s:openapi-gen=true/d'
|
||||
find "${CLIENT_REPO_TEMP}" -type f -name "*.go" -print0 | xargs -0 ${SED} -i '/^\/\/ +k8s:defaulter-gen=/d'
|
||||
|
|
Loading…
Reference in New Issue