From ef3fb05d66f1b5c94dd65ae2d14b691227d6afbe Mon Sep 17 00:00:00 2001
From: Riku Viitanen <riku.viitanen@protonmail.com>
Date: Sun, 3 Sep 2023 17:00:18 +0300
Subject: Less cat abuse

More than 90% of cats were thus terminated.
read (shell built-in) is better at reading, and dogs are better pets.

Signed-off-by: Riku Viitanen <riku.viitanen@protonmail.com>
---
 script/handle/make/config | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

(limited to 'script/handle/make/config')

diff --git a/script/handle/make/config b/script/handle/make/config
index c148ebca..3db91550 100755
--- a/script/handle/make/config
+++ b/script/handle/make/config
@@ -26,8 +26,8 @@ set -u -e
 
 . "include/err.sh"
 
-projectname="$(cat projectname)"
-our_version="$(cat version)"
+read projectname < projectname
+read our_version < version
 
 export LOCALVERSION="-${projectname}-${our_version}"
 
@@ -270,11 +270,11 @@ copy_elf()
 		    err "copy_elf: cannot prepare coreboot image"
 	fi
 
-	for f in $(cat "${listfile}"); do
+	while read f; do
 		[ ! -f "${codedir}/$f" ] || \
 		    cp "${codedir}/${f}" "${dest_dir}/" || \
 		    fail "copy_elf: cannot copy elf file"
-	done
+	done < ${listfile}
 
 	./handle make file -c "${codedir}" || \
 	    fail "copy_elf: clean: ${codedir} (${project}/${target})"
-- 
cgit v1.2.1