- still needs testing
This commit is contained in:
Bernhard Landauer 2017-03-11 19:18:25 +01:00
parent 8cb02c1ca2
commit a4e74218bb
3 changed files with 33 additions and 45 deletions

View File

@ -19,6 +19,7 @@ setup_graphics_card() {
clear
arch_chroot "mhwd -f -i pci $(cat /tmp/.driver)" 2>$ERR
check_for_error "install $(cat /tmp/.driver)" $?
touch /mnt/.video_installed
GRAPHIC_CARD=$(lspci | grep -i "vga" | sed 's/.*://' | sed 's/(.*//' | sed 's/^[ \t]*//')

View File

@ -171,57 +171,19 @@ config_base_menu() {
done
}
install_graphics_menu() {
local PARENT="$FUNCNAME"
declare -i loopmenu=1
while ((loopmenu)); do
submenu 4
DIALOG " $_InstGrMenuTitle " --default-item ${HIGHLIGHT_SUB} --menu "$_InstGrMenuBody" 0 0 4 \
"1" "$_InstGrMenuDD" \
"2" "$_PrepKBLayout" \
"3" "$_InstDEStable|>" \
"4" "$_Back" 2>${ANSWER}
HIGHLIGHT_SUB=$(cat ${ANSWER})
case $(cat ${ANSWER}) in
"1") setup_graphics_card
;;
"2") set_xkbmap
;;
"3") install_manjaro_de_wm_pkg
;;
*) loopmenu=0
return 0
;;
esac
done
}
install_drivers_menu() {
HIGHLIGHT_SUB=1
declare -i loopmenu=1
while ((loopmenu)); do
DIALOG " $_InstDrvTitle " --default-item ${HIGHLIGHT_SUB} --menu "$_InstDrvBody" 0 0 5 \
"1" "$_InstFree" \
"2" "$_InstProp" \
"3" "$_InstGrMenuDD|>" \
"4" "$_InstNWDrv|>" \
"5" "$_Back" 2>${ANSWER}
submenu 3
DIALOG " $_InstDrvTitle " --default-item ${HIGHLIGHT_SUB} --menu "$_InstDrvBody" 0 0 3 \
"1" "$_InstGrMenuTitle|>" \
"2" "$_InstNWDrv" \
"3" "$_Back" 2>${ANSWER}
HIGHLIGHT_SUB=4
case $(cat ${ANSWER}) in
"1") clear
arch_chroot "mhwd -a pci free 0300" 2>$ERR
check_for_error "$_InstFree" $?
"1") install_graphics_menu
;;
"2") clear
arch_chroot "mhwd -a pci nonfree 0300" 2>$ERR
check_for_error "$_InstProp" $?
;;
"3") setup_graphics_card
;;
"4") setup_network_drivers
HIGHLIGHT_SUB=5
"2") setup_network_drivers
;;
*) HIGHLIGHT_SUB=5
loopmenu=0
@ -231,6 +193,28 @@ install_drivers_menu() {
done
}
install_graphics_menu() {
DIALOG " $_InstGrMenuTitle " --menu "$_InstGrMenuBody" 0 0 3 \
"1" "$_InstFree" \
"2" "$_InstProp" \
"3" "$_InstGrMenuDD" 2>${ANSWER} || return 0
case $(cat ${ANSWER}) in
"1") clear
arch_chroot "mhwd -a pci free 0300" 2>$ERR
check_for_error "$_InstFree" $?
touch /mnt/.video_installed
;;
"2") clear
arch_chroot "mhwd -a pci nonfree 0300" 2>$ERR
check_for_error "$_InstProp" $?
touch /mnt/.video_installed
;;
"3") setup_graphics_card
;;
esac
}
edit_configs() {
declare -i loopmenu=1
while ((loopmenu)); do

View File

@ -454,6 +454,9 @@ final_check() {
# Check if fstab is generated
$(grep -qv '^#' /mnt/etc/fstab 2>/dev/null) || echo "- Fstab has not been generated" >> ${CHECKLIST}
# Check if video-driver has been installed
[[ ! -e /mnt/.video_installed ]] && echo "- No graphics driver has been installed" >> ${CHECKLIST}
# Check if locales have been generated
[[ $(manjaro-chroot /mnt 'locale -a' | wc -l) -ge '3' ]] || echo "- Locales have not been generated" >> ${CHECKLIST}