Skip to content

Commit

Permalink
Merge pull request #2 from 89luca89/main
Browse files Browse the repository at this point in the history
  • Loading branch information
sysrich authored May 2, 2024
2 parents ec3d79c + 66882b7 commit c71045d
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions usr/lib/tik/lib/tik-functions
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ get_disk() {
if [ -n "${disk_device_by_id}" ];then
disk_device=${disk_device_by_id}
fi
list_items="${list_items} ${disk_device} ${disk_size}"
list_items="${list_items} $(basename ${disk_device}) ${disk_size}"
done
if [ -n "${TIK_INSTALL_DEVICE}" ];then
# install device overwritten by config.
Expand All @@ -131,7 +131,7 @@ get_disk() {
grep -E "disk|raid" | tr ' ' ":"
)
device_size=$(echo "${device_meta}" | cut -f2 -d:)
list_items="${device} ${device_size}"
list_items="$(basename ${device}) ${device_size}"
message="tik installation device set to to: ${device}"
log "${message}"
fi
Expand All @@ -152,11 +152,13 @@ get_disk() {
done
if [ "${device_index}" -eq 1 ];then
# one single disk device found, use it
TIK_INSTALL_DEVICE="${device_array[0]}"
# Add back full path to it
TIK_INSTALL_DEVICE="/dev/disk/by-id/${device_array[0]}"
else
# manually select from storage list
d --list --column=Disk --column=Size --width=1000 --height=340 --title="Select A Disk" --text="Select the disk to install the operating system to. <b>Make sure any important documents and files have been backed up.</b>\n" ${list_items}
TIK_INSTALL_DEVICE="$result"
# Add back full path to it
TIK_INSTALL_DEVICE="/dev/disk/by-id/$result"
fi
fi
}
Expand Down

0 comments on commit c71045d

Please sign in to comment.