mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-10 21:50:05 +00:00
Use cp instead of rsync in hack/verify-gendocs.sh
Instead of calling rsync over and over and over and over and over and over and over and over and over (and probably over) use one `cp` Before: real 0m5.247s user 0m2.294s sys 0m1.300s After: real 0m2.260s user 0m2.230s sys 0m0.936s
This commit is contained in:
@@ -171,7 +171,11 @@ kube::util::gen-doc() {
|
||||
done <"${dest}/.files_generated"
|
||||
|
||||
# put the new generated file into the destination
|
||||
find "${tmpdir}" -exec rsync -pt {} "${dest}" \; >/dev/null
|
||||
# the shopt is so that we get .files_generated from the glob.
|
||||
shopt -s dotglob
|
||||
cp -af "${tmpdir}"/* "${dest}"
|
||||
shopt -u dotglob
|
||||
|
||||
#cleanup
|
||||
rm -rf "${tmpdir}"
|
||||
}
|
||||
|
Reference in New Issue
Block a user