summaryrefslogtreecommitdiff
path: root/include/mrc.sh
diff options
context:
space:
mode:
authorLeah Rowe <leah@libreboot.org>2025-10-04 02:43:24 +0100
committerLeah Rowe <leah@libreboot.org>2025-10-04 02:43:24 +0100
commit0605fbe72032125c8b430f1454794be40ab61009 (patch)
tree54f2c020a8b3a09f1c84c930680924e90dfb5ccd /include/mrc.sh
parente1c70f43198e7d709026ab7cd0422adc24083bd4 (diff)
xbmk: general cleanup: unroll condensed code lines
i overlooked a number of lines, during previous cleanup Signed-off-by: Leah Rowe <leah@libreboot.org>
Diffstat (limited to 'include/mrc.sh')
-rw-r--r--include/mrc.sh2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/mrc.sh b/include/mrc.sh
index 6bc8632c..d2249aeb 100644
--- a/include/mrc.sh
+++ b/include/mrc.sh
@@ -52,10 +52,12 @@ extract_mrc()
extract_partition()
{
printf "Extracting ROOT-A partition\n"
+
ROOTP=$( printf "unit\nB\nprint\nquit\n" | \
parted "${1%.zip}" 2>/dev/null | grep "ROOT-A" )
START=$(( $( echo $ROOTP | cut -f2 -d\ | tr -d "B" ) ))
+
SIZE=$(( $( echo $ROOTP | cut -f4 -d\ | tr -d "B" ) ))
x_ dd if="${1%.zip}" of="root-a.ext2" bs=1024 skip=$(( $START / 1024 )) \