#54 Fix reading fs type
Merged 3 years ago by pwhalen. Opened 3 years ago by phomes.
phomes/arm-image-installer resize-fs-type  into  master

file modified
+1 -6
@@ -392,12 +392,7 @@ 

  		fi

  	fi

  

- 	if [ "$(echo $IMAGE | grep -i 'armhfp')" = "" ]; then

- 		FS_TYPE=$(blkid "$ROOTPART" | cut -d'"' -f 4)

- 	else

- 		FS_TYPE=$(blkid "$ROOTPART" | cut -d'"' -f 6)

- 	fi

- 

+ 	FS_TYPE=$(blkid "$ROOTPART" -s TYPE -o value)

  	if [ "$FS_TYPE" = "xfs" ] && [ "$LVM_NAME" != "" ]; then

  		mkdir /tmp/root &> /dev/null

  		mount "$ROOTPART" /tmp/root &> /dev/null

Output the fs type directly so we do not have to switch on how to
do the cut.

This got the wrong output on rpi4 so fixes resizing there.

rebased onto 99b2c3a

3 years ago

Pull-Request has been merged by pwhalen

3 years ago
Metadata