mirror of
https://gitlab.archlinux.org/tpowa/archboot.git
synced 2024-09-20 03:50:37 +02:00
fix subdir for btrfs on subvolumes
This commit is contained in:
parent
16548ed65a
commit
145127cf66
1 changed files with 8 additions and 0 deletions
|
@ -3901,8 +3901,16 @@ do_grub_config() {
|
|||
|
||||
if [[ "${ROOT_PART_FS_UUID}" == "${BOOT_PART_FS_UUID}" ]]; then
|
||||
subdir="/boot"
|
||||
# on btrfs we need to check on subvol
|
||||
if [[ $(mount "${DESTDIR}/ " | grep btrfs | grep subvol) ]]; then
|
||||
subdir="$(btrfs subvolume show "${DESTDIR}/" | grep Name | cut -d ":" -f2)"
|
||||
fi
|
||||
else
|
||||
subdir=""
|
||||
# on btrfs we need to check on subvol
|
||||
if [[ $(mount "${DESTDIR}/boot" | grep btrfs | grep subvol) ]]; then
|
||||
subdir="$(btrfs subvolume show "${DESTDIR}/boot" | grep Name | cut -d ":" -f2)"
|
||||
fi
|
||||
fi
|
||||
|
||||
########
|
||||
|
|
Loading…
Reference in a new issue