mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-09 13:12:20 +00:00
verify-generated-files-remake.sh: use 'read -r'.
'read' will not handle backslashes properly. 'read -r' is safer to use. The find_genfiles() will not insert backslashes, so if there are any, they will be from directory names.
This commit is contained in:
@@ -37,7 +37,7 @@ function find_genfiles() {
|
||||
# $1 = filename pattern as in "zz_generated.$1.go"
|
||||
# $2 timestamp file
|
||||
function newer() {
|
||||
find_genfiles "$1" | while read F; do
|
||||
find_genfiles "$1" | while read -r F; do
|
||||
if [[ "${F}" -nt "$2" ]]; then
|
||||
echo "${F}"
|
||||
fi
|
||||
@@ -47,7 +47,7 @@ function newer() {
|
||||
# $1 = filename pattern as in "zz_generated.$1.go"
|
||||
# $2 timestamp file
|
||||
function older() {
|
||||
find_genfiles "$1" | while read F; do
|
||||
find_genfiles "$1" | while read -r F; do
|
||||
if [[ "$2" -nt "${F}" ]]; then
|
||||
echo "${F}"
|
||||
fi
|
||||
|
Reference in New Issue
Block a user