[dual-boot] Avoid overriding Linux UEFI files

This commit is contained in:
Luke Short 2025-05-09 00:10:22 -06:00
commit f1b50c4731
2 changed files with 12 additions and 1 deletions

View file

@ -852,8 +852,13 @@ Only Intel Macs are supported.
- Select the "wos-drive" drive in the Dolphin file manager to automatically mount it.
- Extract the archive.
```
# For macOS and Windows.
$ sudo tar --extract --keep-old-files --verbose --file /run/media/winesap/wos-drive/winesapos-${WINESAPOS_VERSION}-minimal-rootfs.tar.zst --directory /mnt/
```
```
# For Linux, avoid overriding existing UEFI files.
$ sudo tar --extract --keep-old-files --exclude BOOT --verbose --file /run/media/winesap/wos-drive/winesapos-${WINESAPOS_VERSION}-minimal-rootfs.tar.zst --directory /mnt/
```
7. Configure the bootloader.
```
$ grep -v -P "winesapos|WOS" /mnt/etc/fstab | sudo tee /mnt/etc/fstab

View file

@ -90,7 +90,13 @@ fi
echo "DEBUG: winesapOS tarball path is ${winesapos_tarball}"
echo "INFO: Extracintg the rootfs tarball (this will take a long time)..."
sudo tar --extract --keep-old-files --file "${winesapos_tarball}" --directory /mnt/
# Avoid overriding existing Linux UEFI files.
# shellcheck disable=SC2010
if ls /mnt/boot/efi/EFI/ | grep -q -P "(fedora|ubuntu)"; then
sudo tar --extract --keep-old-files --exclude BOOT --file "${winesapos_tarball}" --directory /mnt/
else
sudo tar --extract --keep-old-files --file "${winesapos_tarball}" --directory /mnt/
fi
# Configure the booloader.
## Only get the tmpfs mounts from the original /etc/fstab.