diff options
Diffstat (limited to 'linhes/linhes-system/add_storage.py')
| -rwxr-xr-x | linhes/linhes-system/add_storage.py | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/linhes/linhes-system/add_storage.py b/linhes/linhes-system/add_storage.py index cc6feb5..318e77b 100755 --- a/linhes/linhes-system/add_storage.py +++ b/linhes/linhes-system/add_storage.py @@ -5,7 +5,7 @@ #Disks that are mounted, in fstab, size < 5000 bytes, optical or #have already been seen will not be presented as an option. # -# Version 2.0.2 +# Version 2.1.0 import dbus import pickle @@ -147,7 +147,8 @@ class disk_device: return True def get_is_device(self): - match = re.search(r'part\d+$', self.device_file_path) + #match = re.search(r'part\d+$', self.device_file_path) + match = re.search(r'part\d+$', self.device_id) if match is None: return True else: @@ -214,6 +215,20 @@ class disk_device: if i[1] in mp: fstype = i[2] break + + loop = True + prompt = ''' + Format disk with what filesystem (xfs/ext4)?:''' + + while loop: + str1 = input(prompt) + + if str1 in ['xfs','ext4']: + loop = False + fstype=str1 + break + print("\n") + return fstype def lookup_format(self): |
