summaryrefslogtreecommitdiff
path: root/script
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2023-09-09 23:31:20 +0100
committerLeah Rowe <leah@libreboot.org>2023-09-09 23:31:20 +0100
commit5aef8156b50e0fd2a13c4765a333181346096b09 (patch)
tree613ebc06da416b969ebeed25b41c5729707e37e4 /script
parent76e12cd4a9ab0fb141a4077f973166f796d4a5b8 (diff)
scripts: use printf, not echo, where appropriate
printf has more universal behaviour, across various implementations of sh, so it's better to use this. Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'script')
-rwxr-xr-xscript/build/boot/roms_helper5
-rwxr-xr-xscript/build/release/roms2
-rwxr-xr-xscript/update/blobs/inject2
3 files changed, 5 insertions, 4 deletions
diff --git a/script/build/boot/roms_helper b/script/build/boot/roms_helper
index fb25bba4..5b64ad0e 100755
--- a/script/build/boot/roms_helper
+++ b/script/build/boot/roms_helper
@@ -156,7 +156,7 @@ configure_target()
# Override all payload directives with cmdline args
if [ ! -z ${payloads} ]; then
- echo "setting payloads $payloads"
+ printf "setting payloads %s\n" "$payloads"
payload_grub="n"
payload_grub_withseabios="n" # seabios chainloaded from grub
payload_seabios="n"
@@ -397,7 +397,8 @@ build_grub_roms() {
done
fi
for keymapfile in ${keymaps}; do
- echo "keymaps is $keymaps, keymapfile is $keymapfile"
+ printf "keymaps is %s, keymapfile is %s\n" \
+ "${keymaps}" "${keymapfile}"
[ -f "${keymapfile}" ] || continue
diff --git a/script/build/release/roms b/script/build/release/roms
index da67f8ed..c15087f5 100755
--- a/script/build/release/roms
+++ b/script/build/release/roms
@@ -97,7 +97,7 @@ make_archive()
cp "${builddir}"/* "${romdir}" || \
err "make_archive: cannot copy ROM images directory -> ${romdir}"
- echo ${target}
+ printf "%s\n" "${target}"
microcode_required="y"
. "config/coreboot/${target}/target.cfg"
diff --git a/script/update/blobs/inject b/script/update/blobs/inject
index 06bf48f0..b849f5c5 100755
--- a/script/update/blobs/inject
+++ b/script/update/blobs/inject
@@ -125,7 +125,7 @@ patch_release_roms()
err "patch_release_roms: could not extract release archive"
for x in "${_tmpdir}"/bin/*/*.rom ; do
- echo "patching rom $x"
+ printf "patching rom: %s\n" "$x"
patch_rom "${x}" || err "patch_release_roms: could not patch ${x}"
done
for x in "${_tmpdir}"/bin/*/*_nomicrocode.rom ; do