summaryrefslogtreecommitdiffstats
path: root/util/chromeos
diff options
context:
space:
mode:
authorMatt DeVillier <matt.devillier@gmail.com>2023-02-01 12:33:52 -0600
committerFelix Held <felix-coreboot@felixheld.de>2023-02-10 14:53:58 +0000
commit554c13dc2c7939ac64f092b44928b55630893383 (patch)
tree8d0fdb8d97e8d51627d7575851acf120c1f5ad67 /util/chromeos
parent4bf6f49d12cc2460b2d58d0957ba0d3b31b604c0 (diff)
downloadcoreboot-554c13dc2c7939ac64f092b44928b55630893383.tar.gz
coreboot-554c13dc2c7939ac64f092b44928b55630893383.tar.bz2
coreboot-554c13dc2c7939ac64f092b44928b55630893383.zip
util/chromeos/extract_blobs: allow passing dest dir as arg
Allow user to pass the output dir for the extracted blobs as the 2nd argument to the script; if not provided, fall back to the existing default. Change-Id: I0f120b69e0b6d14c2763b9a3b2a622e77c4fe0d4 Signed-off-by: Matt DeVillier <matt.devillier@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/72910 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com>
Diffstat (limited to 'util/chromeos')
-rwxr-xr-xutil/chromeos/extract_blobs.sh11
1 files changed, 8 insertions, 3 deletions
diff --git a/util/chromeos/extract_blobs.sh b/util/chromeos/extract_blobs.sh
index 669327d3fe67..ca0bdeeee6f1 100755
--- a/util/chromeos/extract_blobs.sh
+++ b/util/chromeos/extract_blobs.sh
@@ -8,9 +8,14 @@ if [ ! -f "$1" ]; then
fi
IMAGE=$1
-# create new dir '$IMAGE-blobs' (less file extension)
-DIR=$(basename $IMAGE)
-DIR="${DIR%.*}-blobs"
+
+if [[ "$2" = "" ]]; then
+ # create new dir '$IMAGE-blobs' (less file extension)
+ DIR=$(basename $IMAGE)
+ DIR="${DIR%.*}-blobs"
+else
+ DIR=$2
+fi
mkdir -p $DIR
if [ -f ./cbfstool ]; then