Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall/lib
diff options
context:
space:
mode:
authorAnton Hvornum <anton@hvornum.se>2021-02-07 13:36:30 +0100
committerAnton Hvornum <anton@hvornum.se>2021-02-07 13:36:30 +0100
commit53cdb607bc9204b69d3f1aac42baea5ddcb94c12 (patch)
treec9a281aaaccd785eb0fb0197edea2f77a0a25fd6 /archinstall/lib
parent9c7f689dd620739062b8248bc9798a522fc4c7e2 (diff)
Added the ability to check if a harddrive has any mountpoint related to a given parameter.
Diffstat (limited to 'archinstall/lib')
-rw-r--r--archinstall/lib/disk.py6
-rw-r--r--archinstall/lib/storage.py3
2 files changed, 8 insertions, 1 deletions
diff --git a/archinstall/lib/disk.py b/archinstall/lib/disk.py
index 1d78d127..aafb07a8 100644
--- a/archinstall/lib/disk.py
+++ b/archinstall/lib/disk.py
@@ -103,6 +103,12 @@ class BlockDevice():
def has_partitions(self):
return len(self.partitions)
+ def has_mount_point(self, mountpoint):
+ for partition in self.partitions:
+ if self.partitions[partition].mountpoint == mountpoint:
+ return True
+ return False
+
class Partition():
def __init__(self, path, part_id=None, size=-1, filesystem=None, mountpoint=None, encrypted=False):
diff --git a/archinstall/lib/storage.py b/archinstall/lib/storage.py
index e881700f..9bda017d 100644
--- a/archinstall/lib/storage.py
+++ b/archinstall/lib/storage.py
@@ -17,5 +17,6 @@ storage = {
'UPSTREAM_URL' : 'https://raw.githubusercontent.com/Torxed/archinstall/master/profiles',
'PROFILE_DB' : None, # Used in cases when listing profiles is desired, not mandatory for direct profile grabing.
'LOG_PATH' : '/var/log/archinstall',
- 'LOG_FILE' : 'install.log'
+ 'LOG_FILE' : 'install.log',
+ 'MOUNT_POINT' : '/mnt'
}