Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall/lib
diff options
context:
space:
mode:
authorWerner Llácer <wllacer@gmail.com>2022-04-03 23:17:25 +0200
committerGitHub <noreply@github.com>2022-04-03 23:17:25 +0200
commit57b16d5468493dbc4b134a43bb55cf52571acb0b (patch)
treeb40bdd020d1f617b8e92e7df486a28e8425ce398 /archinstall/lib
parent656047163ada076640220afd443f28ca64e0a218 (diff)
Partition.boot works now for GPT and MBR disks (issue #1061) (#1063)
Diffstat (limited to 'archinstall/lib')
-rw-r--r--archinstall/lib/disk/partition.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/archinstall/lib/disk/partition.py b/archinstall/lib/disk/partition.py
index 708edd29..bf55145c 100644
--- a/archinstall/lib/disk/partition.py
+++ b/archinstall/lib/disk/partition.py
@@ -172,7 +172,8 @@ class Partition:
for partition in output.get('partitiontable', {}).get('partitions', []):
if partition['node'] == self.path:
- return partition.get('bootable', False)
+ # first condition is for MBR disks, second for GPT disks
+ return partition.get('bootable', False) or partition.get('type','') == 'C12A7328-F81F-11D2-BA4B-00A0C93EC93B'
return False
@@ -440,7 +441,7 @@ class Partition:
def unmount(self) -> bool:
worker = SysCommand(f"/usr/bin/umount {self.path}")
-
+
# Without to much research, it seams that low error codes are errors.
# And above 8k is indicators such as "/dev/x not mounted.".
# So anything in between 0 and 8k are errors (?).