Codegen: git grep returns non-zero if no match

This commit is contained in:
Tim Hockin 2023-03-04 16:28:21 -08:00
parent 241d46d1dd
commit 64ecb161d4
No known key found for this signature in database

View File

@ -724,10 +724,11 @@ function codegen::applyconfigs() {
done
fi
git_grep -l --null \
(git_grep -l --null \
-e '^// Code generated by applyconfiguration-gen. DO NOT EDIT.$' \
-- \
':(glob)staging/src/k8s.io/client-go/**/*.go' \
|| true) \
| xargs -0 rm -f
"${applyconfigurationgen}" \
@ -776,10 +777,11 @@ function codegen::clients() {
done
fi
git_grep -l --null \
(git_grep -l --null \
-e '^// Code generated by client-gen. DO NOT EDIT.$' \
-- \
':(glob)staging/src/k8s.io/client-go/**/*.go' \
|| true) \
| xargs -0 rm -f
"${clientgen}" \
@ -819,10 +821,11 @@ function codegen::listers() {
done
fi
git_grep -l --null \
(git_grep -l --null \
-e '^// Code generated by lister-gen. DO NOT EDIT.$' \
-- \
':(glob)staging/src/k8s.io/client-go/**/*.go' \
|| true) \
| xargs -0 rm -f
"${listergen}" \
@ -859,10 +862,11 @@ function codegen::informers() {
done
fi
git_grep -l --null \
(git_grep -l --null \
-e '^// Code generated by informer-gen. DO NOT EDIT.$' \
-- \
':(glob)staging/src/k8s.io/client-go/**/*.go' \
|| true) \
| xargs -0 rm -f
"${informergen}" \