diff mbox series

[oe-layersetup,PATCHv2,09/16] oe-layertool-setup: eliminate useless cat

Message ID 20230614034507.598391-10-res.sapp@gmail.com
State Accepted
Delegated to: Ryan Eatmon
Headers show
Series Sacrifice your first born to the linter | expand

Commit Message

Res Sapp June 14, 2023, 3:45 a.m. UTC
Eliminate useless cat into grep.

Signed-off-by: Randolph Sapp <res.sapp@gmail.com>
---
 oe-layertool-setup.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/oe-layertool-setup.sh b/oe-layertool-setup.sh
index 6908fe2..b824114 100755
--- a/oe-layertool-setup.sh
+++ b/oe-layertool-setup.sh
@@ -803,7 +803,7 @@  EOM
     # Find if old DL_DIR was set
     if [ -e "$confdir/local.conf.bak" ]
     then
-        old_dldir=$(cat "$confdir/local.conf.bak" | grep -e "^DL_DIR =" | sed 's|DL_DIR = ||' | sed 's/"//g')
+        old_dldir=$(grep -e "^DL_DIR =" "$confdir/local.conf.bak" | sed 's|DL_DIR = ||' | sed 's/"//g')
     else
         old_dldir="$oebase/downloads"
     fi