File tree Expand file tree Collapse file tree 1 file changed +7
-7
lines changed
sdk-platform-java/hermetic_build/library_generation/utils Expand file tree Collapse file tree 1 file changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -335,14 +335,14 @@ error_if_not_exists() {
335335}
336336
337337normalize_owlbot_yaml () {
338- local input_file=$1
339- local output_file=$2
340- local library_name=$3
338+ local input_file=" $1 "
339+ local output_file=" $2 "
340+ local library_name=" $3 "
341341
342342 # Step 1: Remove library name prefix and normalize indentation for matching lines.
343343 # Step 2: Normalize indentation for lines that didn't have the prefix.
344- cat " ${input_file} " \
345- | sed -e " s/^[[:space:]] *- \" \ /${library_name} / - \" / " \
346- -e " s/^[[:space:]] *- \" / - \" / " \
347- > " ${output_file} "
344+ # Using | as sed delimiter to avoid escaping forward slashes.
345+ sed -e " s|^\s *- \" /${library_name} | - \" | " \
346+ -e " s|^\s *- \" | - \" | " \
347+ " ${input_file} " > " ${output_file} "
348348}
You can’t perform that action at this time.
0 commit comments