Change: Graphics Setup stage has been revamped

Change: 'Budgie' desktop > 'Nautilus' file browser has been replaced by 'Nemo'
Add: When 'GPT Manager' creates a new disk GPT, all future warnings concerning 'Data Loss' when dealing with involved disk will be silenced
Add: When 'GPT Manager' creates a new disk GPT, the 'Multiboot Status' stage will be skipped
This commit is contained in:
Jane Doe
2025-10-10 17:46:20 +03:00
parent 64d692d0ff
commit 79be8ff2cb
+228 -322
View File
@@ -2,7 +2,7 @@
# Amelia Installer
# Source: https://gitlab.com/prism7/archery
# Version: 9.8.4
# Version: 9.9.0
set -euo pipefail
###################################################################################################
@@ -542,10 +542,9 @@ ${magenta}###${nc}------------------------------------${magenta}[ ${bwhite}Machi
hardw_vendor="$(hostnamectl | grep -E "Hardware Vendor" | awk "{print \$3}")"
machine="$(hostnamectl | grep -Em 1 "Chassis" | awk "{print \$2}")"
if [[ "${hypervisor}" != "none" ]]; then
if [[ "${hypervisor}" == "none" ]]; then # <<<<<<<<<<
vm
vendor="Virtual Machine"
gfxconf="n"
fi
if [[ "${CPU}" == *"GenuineIntel"* ]]; then
@@ -1570,10 +1569,8 @@ Enter Swap size ${bwhite}(in GB)${blue}: "
dtct_gfx() {
gfx_slct="yes"
vendor=""
vendors=""
if [[ "${hypervisor}" != "none" ]]; then
vendor="Virtual Machine"
if [[ "${vendor}" == "Virtual Machine" ]]; then
vm
sleep 0.2
YELLOW "
@@ -1581,7 +1578,7 @@ dtct_gfx() {
--> Graphics Setup skipped
"
return 0
else
fi
sleep 0.2
NC "
@@ -1597,11 +1594,10 @@ ${magenta}###${nc}-------------------------------------${magenta}[ ${bwhite}Grap
nvidiacount="$(lspci | grep -E 'VGA|Display|3D' | grep -E -c 'NVIDIA Corporation')"
nvidiacards="$(lspci | grep -E 'VGA|Display|3D' | grep -E 'NVIDIA Corporation'| sed 's/.*Corporation //g' | cat --number | sed 's/.[0-9]//')"
if [[ "${gfxcount}" == "1" ]]; then
dtct_single_gfx
else
dtct_multi_gfx
fi
if [[ "${gfxcount}" == "1" ]]; then
dtct_single_gfx
else
dtct_multi_gfx
fi
}
###################################################################################################
@@ -1619,242 +1615,145 @@ dtct_single_gfx() {
amd
elif [[ "${nvidiacount}" -eq "1" ]]; then
vendor="Nvidia"
sourcetype="Proprietary"
nvidia
fi
if [[ "${vendor}" == "Nvidia" ]]; then
sleep 0.2
RED "
----------------------------------------------------
### ${nc}Only for NV110 ${yellow}(Maxwell) ${nc}Graphics or newer ${red}###
----------------------------------------------------"
fi
YELLOW "
> Configure the Graphics subsystem and enable HW acceleration ? [Y/n] "
if [[ "${vendor}" == "Nvidia" ]]; then
CYAN "
### ${yellowl}Nvidia: ${nc}ONLY 'Maxwell' (NV110) or newer graphics are supported ${cyan}
### ${nc}Selecting ${yellowl}(n)o ${nc}defaults to the open-source ${yellowl}'nouveau' "
YELLOW "
### Selecting ${nc}'(n)o' ${yellow}defaults to using the open-source ${nc}'nouveau' ${yellow}driver"
fi
> Install proprietary Nvidia drivers ? [Y/n] "
BLUE "
Enter [Y/n]: "
read -r -p "
==> " gfxconf
==> " nvdprop
gfxconf="${gfxconf:-y}"
gfxconf="${gfxconf,,}"
nvdprop="${nvdprop:-y}"
nvdprop="${nvdprop,,}"
if [[ "${gfxconf}" == "y" ]]; then
gfx_conf
elif [[ "${gfxconf}" == "n" ]]; then
local prompt="Graphics Setup"
skip
ok
else
invalid
return 1
if [[ "${nvdprop}" == "y" ]]; then
sourcetype="Proprietary"
elif [[ "${nvdprop}" == "n" ]]; then
sourcetype="Open-source"
skip
elif [[ ! "${nvdprop}" =~ ^(y|n)$ ]]; then
invalid
return 1
fi
fi
gfx_conf
}
###################################################################################################
dtct_multi_gfx() {
if [[ "${gfxcount}" == "2" ]]; then
gfx_setup="Dual"
elif [[ "${gfxcount}" == "3" ]]; then
gfx_setup="Triple"
fi
sleep 0.2
YELLOW "
### ${gfx_setup} Graphics setup detected, consisting of: "
### Multi Graphics Setup detected, consisting of: "
NC "
____________________________________________________________________"
if [[ "${intelcount}" -ge "1" ]]; then
vendor1="Intel"
echo
BLUEBG " ------------------------------- "
BLUEBG " [${intelcount}] Intel Graphics device(s) "
BLUEBG " ------------------------------- "
NC "
${intelcards}
____________________________________________________________________"
fi
if [[ "${amdcount}" -ge "1" ]]; then
vendor2="AMD"
echo
REDBG " ------------------------------- "
REDBG " [${amdcount}] AMD Graphics device(s) "
REDBG " ------------------------------- "
NC "
${amdcards}
____________________________________________________________________"
fi
if [[ "${nvidiacount}" -ge "1" ]]; then
vendor3="Nvidia"
echo
GREENBG " ------------------------------- "
GREENBG " [${nvidiacount}] Nvidia Graphics device(s) "
GREENBG " ------------------------------- "
NC "
${nvidiacards}
${cyan}### ${yellowl}Nvidia: ${nc}ONLY 'Maxwell' (NV110) or newer graphics are supported ${cyan}
### ${nc}Selecting ${yellowl}(n)o ${nc}defaults to the open-source ${yellowl}'nouveau' ${nc}driver
____________________________________________________________________"
fi
YELLOW "
> Configure the Graphics subsystem and enable HW acceleration for : "
if [[ -n "${vendor1}" && -n "${vendor2}" ]]; then
NC "
[1] Intel
[2] AMD
[3] Both
[4] None "
> Install proprietary Nvidia drivers ? [Y/n] "
BLUE "
Enter a number: "
Enter [Y/n]: "
read -r -p "
==> " vendor_slct
==> " nvdprop
case "${vendor_slct}" in
1)
vendor="Intel" ;;
2)
vendor="AMD" ;;
3)
vendors="Intel & AMD" ;;
4)
vendor="none" ;;
"")
choice
return 1 ;;
*)
invalid
return 1 ;;
esac
nvdprop="${nvdprop:-y}"
nvdprop="${nvdprop,,}"
elif [[ -n "${vendor1}" && -n "${vendor3}" ]]; then
NC "
[1] Intel
${red}----------------------------------------------------${nc}
[2] Nvidia ${red}### ${nc}Only for NV110 ${yellow}(Maxwell) ${nc}Graphics or newer ${red}###${nc}
${red}----------------------------------------------------${nc}
[3] Both
[4] None "
BLUE "
Enter a number: "
read -r -p "
==> " vendor_slct
case "${vendor_slct}" in
1)
vendor="Intel" ;;
2)
vendor="Nvidia" ;;
3)
vendors="Intel & Nvidia" ;;
4)
vendor="none" ;;
"")
choice
return 1 ;;
*)
invalid
return 1 ;;
esac
elif [[ -n "${vendor2}" && -n "${vendor3}" ]]; then
NC "
[1] Amd
${red}----------------------------------------------------${nc}
[2] Nvidia ${red}### ${nc}Only for NV110 ${yellow}(Maxwell) ${nc}Graphics or newer ${red}###${nc}
${red}----------------------------------------------------${nc}
[3] Both
[4] None "
BLUE "
Enter a number: "
read -r -p "
==> " vendor_slct
case "${vendor_slct}" in
1)
vendor="AMD" ;;
2)
vendor="Nvidia" ;;
3)
vendors="AMD & Nvidia" ;;
4)
vendor="none" ;;
"")
choice
return 1 ;;
*)
invalid
return 1 ;;
esac
if [[ "${nvdprop}" == "n" ]]; then
skip
elif [[ ! "${nvdprop}" =~ ^(y|n)$ ]]; then
invalid
return 1
fi
fi
if [[ "${vendor}" =~ ^(intel|AMD)$ ]]; then
sourcetype="Open-source"
gfxconf="y"
multivendors=()
multisourcetype=()
if [[ "${intelcount}" -ge "1" ]]; then
multivendors+=(Intel)
multisourcetype+=(Open-source)
fi
if [[ "${amdcount}" -ge "1" ]]; then
multivendors+=(AMD)
multisourcetype+=(Open-source)
fi
if [[ "${nvidiacount}" -ge "1" ]]; then
multivendors+=(Nvidia)
if [[ "${nvdprop}" == "y" ]]; then
multisourcetype+=(Proprietary)
else
multisourcetype+=(Open-source)
fi
fi
vendors="${multivendors[*]}"
sourcetype="${multisourcetype[*]}"
if [[ "${sourcetype}" =~ "Open-source" && "${sourcetype}" =~ "Proprietary" ]]; then
sourcetype="Open-source & Proprietary"
elif [[ "${sourcetype}" =~ "Open-source" ]]; then
sourcetype="Open-source"
elif [[ "${sourcetype}" =~ "Proprietary" ]]; then
sourcetype="Proprietary"
fi
gfx_conf
elif [[ "${vendor}" == "Nvidia" ]]; then
sourcetype="Proprietary"
gfxconf="y"
gfx_conf
elif [[ "${vendors}" == "Intel & AMD" ]]; then
sourcetype="Open-source"
gfxconf="y"
gfx_conf
elif [[ "${vendors}" =~ ^(Intel & Nvidia|AMD & Nvidia)$ ]]; then
sourcetype="Open-source & Proprietary"
gfxconf="y"
gfx_conf
elif [[ "${vendor}" == "none" ]]; then
local prompt="Graphics Setup"
gfxconf="n"
skip
ok
fi
}
###################################################################################################
gfx_conf() {
if [[ "${vendor}" != "none" ]]; then
sleep 0.2
YELLOW "
### ${sourcetype} drivers will be used
"
fi
if [[ "${vendor}" == "AMD" || "${vendors}" =~ "AMD" ]]; then
sleep 0.2
@@ -1897,7 +1796,8 @@ Enter a number ${bwhite}(empty to skip)${blue}: "
esac
fi
if [[ "${vendor}" == "Nvidia" || "${vendors}" =~ "Nvidia" ]]; then
if [[ "${nvdprop}" == "y" ]]; then
sleep 0.2
YELLOW "
> Select Nvidia architecture: "
@@ -1985,7 +1885,7 @@ Enter [Y/n]: "
sleep 0.2
YELLOW "
### ${vendor}${vendors} Graphics will be automatically configured
### Graphics will be automatically configured
"
local prompt="Graphics Setup"
ok
@@ -1996,71 +1896,69 @@ gfxpkgs_set() {
# Graphics packages
gfxpkgs=()
# Configure Graphics = yes
if [[ "${gfxconf}" == "y" ]]; then
# Intel Graphics
if [[ "${vendor}" == "Intel" || "${vendors}" =~ "Intel" ]]; then
# /etc/sysctl.d/99-sysctld.conf
perf_stream="dev.i915.perf_stream_paranoid = 0"
gfxpkgs+=(intel-compute-runtime intel-media-driver intel-media-sdk libva-intel-driver libva-utils libvpl opencl-headers vpl-gpu-rt vkd3d vulkan-intel vulkan-mesa-layers)
fi
# AMD Graphics
if [[ "${vendor}" == "AMD" || "${vendors}" =~ "AMD" ]]; then
gfxpkgs+=(libva-mesa-driver mesa-utils mesa-vdpau opencl-headers rocm-opencl-runtime vkd3d vulkan-mesa-layers vulkan-radeon)
fi
# Nvidia Graphics
if [[ "${vendor}" == "Nvidia" || "${vendors}" =~ "Nvidia" ]]; then
# Swap partition|swapfile|zram-swap = yes
if [[ "${swapmode}" =~ ^(1|2|3)$ ]]; then
sleep 0.2
CYAN "
----------------------------------------------------------------
# Intel Graphics
if [[ "${vendor}" == "Intel" || "${vendors}" =~ "Intel" ]]; then
# /etc/sysctl.d/99-sysctld.conf
perf_stream="dev.i915.perf_stream_paranoid = 0"
gfxpkgs+=(intel-compute-runtime intel-media-driver intel-media-sdk libva-intel-driver libva-utils libvpl opencl-headers vpl-gpu-rt vkd3d vulkan-intel vulkan-mesa-layers)
fi
# AMD Graphics
if [[ "${vendor}" == "AMD" || "${vendors}" =~ "AMD" ]]; then
gfxpkgs+=(libva-mesa-driver mesa-utils mesa-vdpau opencl-headers rocm-opencl-runtime vkd3d vulkan-mesa-layers vulkan-radeon)
fi
# Nvidia Graphics
if [[ "${nvdprop}" == "y" ]]; then
# Swap partition|swapfile|zram-swap = yes
if [[ "${swapmode}" =~ ^(1|2|3)$ ]]; then
sleep 0.2
NC "
----------------------------------------------------------------${cyan}
### ${yellowl}INFO: ${nc}When Hibernating ${cyan}###
### ${nc}Nvidia's ${yellowl}'Preserve Video Memory after suspend' ${nc}feature ${cyan}###
### ${nc}is incompatible with ${yellowl}'Early KMS' ${nc}use ${cyan}###
### ${nc}is incompatible with ${yellowl}'Early KMS' ${nc}use ${cyan}###${nc}
----------------------------------------------------------------"
NC "
NC "
${bwhite}Press any key to continue${nc}
"
read -r -s -n 1
"
read -r -s -n 1
fi
gfxpkgs=(libva-mesa-driver libva-nvidia-driver libvdpau-va-gl nvidia-settings nvidia-utils opencl-nvidia opencl-headers vkd3d)
# Turing+ GPUs
if [[ "${family}" == "1" ]]; then
# Linux Kernel
if [[ "${kernelnmbr}" == "1" ]]; then
nvname="nvidia-open"
gfxpkgs+=(nvidia-open)
# Other Kernels
else
gfxpkgs+=(nvidia-open-dkms)
fi
# Turing+ GPUs
if [[ "${family}" == "1" ]]; then
# Linux Kernel
if [[ "${kernelnmbr}" == "1" ]]; then
nvname="nvidia-open"
gfxpkgs+=(libva-mesa-driver libva-nvidia-driver libvdpau-va-gl nvidia-open nvidia-settings nvidia-utils opencl-nvidia opencl-headers vkd3d)
# Other Kernels
else
gfxpkgs+=(libva-mesa-driver libva-nvidia-driver libvdpau-va-gl nvidia-open-dkms nvidia-settings nvidia-utils opencl-nvidia opencl-headers vkd3d)
fi
# Maxwell+ GPUs
elif [[ "${family}" == "2" ]]; then
# Linux Kernel
if [[ "${kernelnmbr}" == "1" ]]; then
nvname="nvidia"
gfxpkgs+=(libva-mesa-driver libva-nvidia-driver libvdpau-va-gl nvidia nvidia-settings nvidia-utils opencl-nvidia opencl-headers vkd3d)
# Linux LTS Kernel
elif [[ "${kernelnmbr}" == "2" ]]; then
nvname="nvidia-lts"
gfxpkgs+=(libva-mesa-driver libva-nvidia-driver libvdpau-va-gl nvidia-lts nvidia-settings nvidia-utils opencl-nvidia opencl-headers vkd3d)
# Other Kernels
else
gfxpkgs+=(libva-mesa-driver libva-nvidia-driver libvdpau-va-gl nvidia-dkms nvidia-settings nvidia-utils opencl-nvidia opencl-headers vkd3d)
fi
# Maxwell+ GPUs
elif [[ "${family}" == "2" ]]; then
# Linux Kernel
if [[ "${kernelnmbr}" == "1" ]]; then
nvname="nvidia"
gfxpkgs+=(nvidia)
# Linux LTS Kernel
elif [[ "${kernelnmbr}" == "2" ]]; then
nvname="nvidia-lts"
gfxpkgs+=(nvidia-lts)
# Other Kernels
else
gfxpkgs+=(nvidia-dkms)
fi
fi
# Configure Graphics = no
elif [[ "${gfxconf}" == "n" ]]; then
# Nvidia Graphics
if [[ "${vendor}" == "Nvidia" || "${vendors}" =~ "Nvidia" ]]; then
gfxpkgs+=(libva-mesa-driver vulkan-nouveau)
fi
elif [[ "${nvdprop}" == "n" ]]; then
gfxpkgs+=(libva-mesa-driver vulkan-nouveau)
fi
}
###################################################################################################
@@ -2510,7 +2408,7 @@ print_scan() {
${magenta}###${nc}--------------------------------${magenta}[ ${bwhite}Printer & Scanner Support${nc} ${magenta}]${nc}--------------------------------${magenta}###
"
local prompt="Printer & Scanner Support"
if [[ "${hypervisor}" == "none" ]]; then
if [[ "${vendor}" != "Virtual Machine" ]]; then
if [[ ! "${desktop}" =~ ^(11|12)$ && -n "${desktop}" ]]; then
sleep 0.2
YELLOW "
@@ -2582,7 +2480,7 @@ Enter [y/N]: "
###################################################################################################
boot_entr() {
if [[ "${hypervisor}" != "none" ]]; then
if [[ "${vendor}" == "Virtual Machine" ]]; then
efi_entr_del="yes"
vm
sleep 0.2
@@ -2913,7 +2811,7 @@ Enter [v/y/N]: "
###################################################################################################
ask_wireless_regdom() {
if [[ "${hypervisor}" != "none" ]]; then
if [[ "${vendor}" == "Virtual Machine" ]]; then
vm
sleep 0.2
YELLOW "
@@ -3381,6 +3279,8 @@ Enter a number: "
sgdisk -o "${gptdrive}" > "${void}" &&
parttable="$(fdisk -l "${gptdrive}" 2> "${void}" | grep '^Disklabel type' | awk "{print \$3}")"
if [[ "${parttable}" == "gpt" ]]; then
multibooting="n"
nowarning="y"
gptok="yes"
sleep 0.2
NC "
@@ -3416,6 +3316,8 @@ ______________________________________________
gdisk "${gptdrive}"
parttable="$(fdisk -l "${gptdrive}" 2> "${void}" | grep '^Disklabel type' | awk "{print \$3}")"
if [[ "${parttable}" == "gpt" ]]; then
multibooting="n"
nowarning="y"
gptok="yes"
sleep 0.2
NC "
@@ -3466,6 +3368,8 @@ ______________________________________________
###################################################################################################
ask_multibooting() {
[[ "${multibooting}" == "n" ]] && return 0
local prompt="MultiBoot Status"
sleep 0.2
NC "
@@ -3475,13 +3379,13 @@ ${magenta}###${nc}------------------------------------${magenta}[ ${bwhite}Multi
YELLOW "
> Are you Dual/Multi-Booting with other OS's ? [y/n]
### If ${nc}'(y)es'${yellow} then: "
> Are you Dual/Multi-Booting with other OS's ? [y/n] "
CYAN "
### ${nc}If ${yellowl}'(y)es'${nc} then:${cyan}
>> ${nc}Your ${yellowl}EFI ${nc}System Partition (ESP) will stay ${yellowl}intact${nc}${cyan}
>> ${nc}Only ${yellowl}Manual ${nc}Disk Partitioning will be available for ${yellowl}Disk Management
@@ -3573,12 +3477,14 @@ auto_part() {
${magenta}###${nc}---------------------------------${magenta}[ ${bwhite}Automatic Partitioning${nc} ${magenta}]${nc}---------------------------------${magenta}###
"
if [[ -e "${instl_drive}" ]]; then
sleep 0.2
line2
REDBG " ------------------------------------------------------------ "
REDBG " [!] WARNING: All data on selected disk will be destroyed [!] "
REDBG " ------------------------------------------------------------ "
line2
if [[ -z "${nowarning}" ]]; then
sleep 0.2
line2
REDBG " ------------------------------------------------------------ "
REDBG " [!] WARNING: All data on selected disk will be destroyed [!] "
REDBG " ------------------------------------------------------------ "
line2
fi
sgdsk_nmbr="${instl_dsk_nmbr}"
sgdrive="$(echo "${disks}" | awk "\$1 == ${sgdsk_nmbr} {print \$2}")"
capacity="$(fdisk -l "${sgdrive}" | grep -E 'bytes' | grep -E 'Disk' | awk "{print \$5}")"
@@ -3704,12 +3610,14 @@ manual_presets() {
${magenta}###${nc}------------------------------------${magenta}[ ${bwhite}Preset Selection${nc} ${magenta}]${nc}------------------------------------${magenta}###
"
sleep 0.2
line2
REDBG " ------------------------------------------------------------ "
REDBG " [!] WARNING: All data on selected disk will be destroyed [!] "
REDBG " ------------------------------------------------------------ "
line2
if [[ -z "${nowarning}" ]]; then
sleep 0.2
line2
REDBG " ------------------------------------------------------------ "
REDBG " [!] WARNING: All data on selected disk will be destroyed [!] "
REDBG " ------------------------------------------------------------ "
line2
fi
YELLOW "
> Select a Partition Layout Preset: "
@@ -4931,7 +4839,7 @@ instl() {
until slct_swap; do : ; done
fi
if [[ "${hypervisor}" == "none" && -z "${gfx_slct}" ]]; then
if [[ "${vendor}" != "Virtual Machine" && -z "${gfx_slct}" ]]; then
local stage_prompt="Graphics Setup"
completion_err
until dtct_gfx; do : ; done
@@ -4951,7 +4859,7 @@ instl() {
fi
fi
if [[ "${hypervisor}" == "none" ]]; then
if [[ "${vendor}" != "Virtual Machine" ]]; then
if [[ -z "${printer}" ]]; then
if [[ ! "${desktop}" =~ ^(11|12)$ ]]; then
until print_scan; do : ; done
@@ -4968,20 +4876,22 @@ instl() {
local stage_prompt="Optimizations"
completion_err
until ask_optm; do : ; done
if [[ "${askoptm}" == "y" ]]; then
until cust_kern_param; do : ; done
until sys_watchdog; do : ; done
until gen_optm; do : ; done
if [[ "${hypervisor}" == "none" ]]; then
until ask_wireless_regdom; do : ; done
fi
until systemd_oomd; do : ; done
until irqbalance; do : ; done
until thermald; do : ; done
until rngd; do : ; done
until rtkit; do : ; done
if [[ "${askoptm}" == "y" ]]; then
until cust_kern_param; do : ; done
until sys_watchdog; do : ; done
until gen_optm; do : ; done
if [[ "${vendor}" != "Virtual Machine" ]]; then
until ask_wireless_regdom; do : ; done
fi
until systemd_oomd; do : ; done
until irqbalance; do : ; done
until thermald; do : ; done
until rngd; do : ; done
until rtkit; do : ; done
if [[ "${vendor}" != "Virtual Machine" ]]; then
until tlp; do : ; done
fi
fi
fi
until instl_dsk; do : ; done
until ask_crypt; do : ; done
@@ -5920,27 +5830,23 @@ ${magenta}###${nc}-------------------------------${magenta}[ ${bwhite}Confirm In
###################################################################################################
revise() {
reset=(xbootloader="" gfxconf="" vendor_slct="" vendor="" desktop="" terminal="" custompkgs="" customservices="" cust_bootopts="" REGDOM="" autoroot="" autoxboot="" autohome="" autoswap="" vendors="" lowlat="" nogsp="" sanity="" partok="" preset="" set_optm="" ask_param="" kill_watchdog="" genoptm="" desk_setup="" devel="" web="" web_pkg="" web_aur="" web_slct="" set_optm_slct="" oomd="" irqbalance="" thermald="" rngd="" rtkit="" tlp="" CRYPTPASS="" CRYPTPASS2="" askoptm="" gptslct="" gptok="" gptabort="")
reset=(xbootloader="" desktop="" terminal="" custompkgs="" customservices="" cust_bootopts="" REGDOM="" autoroot="" autoxboot="" autohome="" autoswap="" lowlat="" nogsp="" sanity="" partok="" preset="" set_optm="" ask_param="" kill_watchdog="" genoptm="" desk_setup="" devel="" web="" web_pkg="" web_aur="" web_slct="" set_optm_slct="" oomd="" irqbalance="" thermald="" rngd="" rtkit="" tlp="" CRYPTPASS="" CRYPTPASS2="" askoptm="" gptslct="" gptok="" gptabort="" nvdprop="" nowarning="")
export "${reset[@]}"
gfxpkgs=()
if [[ "${hypervisor}" != "none" ]]; then
vendor="Virtual Machine"
gfxconf="n"
fi
until slct_krnl; do : ; done
until ask_sign; do : ; done
until slct_bootldr; do : ; done
until slct_espmnt; do : ; done
until slct_fs; do : ; done
until slct_swap; do : ; done
if [[ "${hypervisor}" == "none" ]]; then
if [[ "${vendor}" != "Virtual Machine" ]]; then
until dtct_gfx; do : ; done
fi
until dsktp_slct; do : ; done
until base_devel; do : ; done
until web_browser; do : ; done
if [[ "${hypervisor}" == "none" ]]; then
if [[ "${vendor}" != "Virtual Machine" ]]; then
until print_scan; do : ; done
until boot_entr; do : ; done
fi
@@ -5948,7 +5854,7 @@ revise() {
until cust_kern_param; do : ; done
until sys_watchdog; do : ; done
until gen_optm; do : ; done
if [[ "${hypervisor}" == "none" ]]; then
if [[ "${vendor}" != "Virtual Machine" ]]; then
until ask_wireless_regdom; do : ; done
fi
until systemd_oomd; do : ; done
@@ -5956,7 +5862,9 @@ revise() {
until thermald; do : ; done
until rngd; do : ; done
until rtkit; do : ; done
until tlp; do : ; done
if [[ "${vendor}" != "Virtual Machine" ]]; then
until tlp; do : ; done
fi
fi
until instl_dsk; do : ; done
until ask_crypt; do : ; done
@@ -6382,7 +6290,7 @@ ${magenta}###${nc}-------------------------------------${magenta}[ ${bwhite}Pacs
if [[ -n "${gfxpkgs[*]}" ]]; then
basepkgs+=("${gfxpkgs[*]}")
fi
if [[ "${vendor}" == "Nvidia" ]]; then
if [[ "${nvdprop}" == "y" ]]; then
basepkgs+=("${kernel}-headers")
fi
if [[ -n "${devel}" ]]; then
@@ -6429,7 +6337,7 @@ ${magenta}###${nc}-------------------------------------${magenta}[ ${bwhite}Pacs
displaymanager="lightdm" ;;
8) # Budgie Desktop:
deskpkgs="${basepkgs[*]} blueman budgie gnome-user-share gtk-engine-murrine lightdm-gtk-greeter materia-gtk-theme nautilus network-manager-applet openssh papirus-icon-theme power-profiles-daemon rygel"
deskpkgs="${basepkgs[*]} blueman budgie gnome-user-share gtk-engine-murrine lightdm-gtk-greeter materia-gtk-theme nemo network-manager-applet openssh papirus-icon-theme power-profiles-daemon rygel"
displaymanager="lightdm" ;;
9) # Lxqt Desktop:
@@ -6463,6 +6371,9 @@ ${magenta}###${nc}-------------------------------------${magenta}[ ${bwhite}Pacs
if [[ -n "${gfxpkgs[*]}" ]]; then
custarray+=("${gfxpkgs[*]}")
fi
if [[ "${nvdprop}" == "y" ]]; then
custarray+=("${kernel}-headers")
fi
if [[ "${greeternmbr}" =~ ^(1|2|3)$ ]]; then
custarray+=("${greeter}")
fi
@@ -6687,7 +6598,7 @@ GRUB_BTRFSD
fi
fi
if [[ "${gfxconf}" == "y" && "${vendor}" == "Nvidia" ]]; then
if [[ "${nvdprop}" == "y" ]]; then
local stage_prompt="Grub/Nvidia Configuration"
if arch-chroot /mnt <<-NVGRUB > "${void}" 2>&1 2> "${log}" ; then
sed -i "/^#GRUB_TERMINAL_OUTPUT=console/s/^#//" /etc/default/grub || exit
@@ -6759,32 +6670,30 @@ ZRAMCONF
###################################################################################################
nvidia_hook() {
if [[ "${gfxconf}" == "y" && "${vendor}" == "Nvidia" ]] || [[ "${gfxconf}" == "y" && "${vendors}" =~ "Nvidia" ]]; then
if [[ "${nvname}" =~ ^(nvidia-open|nvidia|nvidia-lts)$ ]]; then
local stage_prompt="Nvidia Hook Creation"
if arch-chroot /mnt <<-NVIDIAHOOK > "${void}" 2>&1 2> "${log}" ; then
mkdir -p /etc/pacman.d/hooks/ || exit
cat <<-HOOK > /etc/pacman.d/hooks/nvidia.hook || exit
[Trigger]
Operation=Install
Operation=Upgrade
Operation=Remove
Type=Package
Target=${nvname}
Target=${kernel}
if [[ "${nvdprop}" == "y" && -n "${nvname}" ]]; then
local stage_prompt="Nvidia Hook Creation"
if arch-chroot /mnt <<-NVIDIAHOOK > "${void}" 2>&1 2> "${log}" ; then
mkdir -p /etc/pacman.d/hooks/ || exit
cat <<-HOOK > /etc/pacman.d/hooks/nvidia.hook || exit
[Trigger]
Operation=Install
Operation=Upgrade
Operation=Remove
Type=Package
Target=${nvname}
Target=${kernel}
[Action]
Description=Update NVIDIA module in initcpio
Depends=mkinitcpio
When=PostTransaction
NeedsTargets
Exec=/bin/sh -c 'while read -r trg; do case $trg in linux*) exit 0; esac; done; /usr/bin/mkinitcpio -P'
[Action]
Description=Update NVIDIA module in initcpio
Depends=mkinitcpio
When=PostTransaction
NeedsTargets
Exec=/bin/sh -c 'while read -r trg; do case $trg in linux*) exit 0; esac; done; /usr/bin/mkinitcpio -P'
HOOK
NVIDIAHOOK
stage_ok
else
stage_fail
fi
stage_ok
else
stage_fail
fi
fi
}
@@ -7290,10 +7199,10 @@ set_vars() {
fi
# HOOKS SETUP (Encryption)
# Nvidia Vendor
if [[ "${vendor}" == "Nvidia" ]]; then
# Nvidia Proprietary Driver
if [[ "${nvdprop}" == "y" ]]; then
HOOKS+=(systemd keyboard autodetect microcode modconf sd-vconsole block sd-encrypt filesystems)
# Other Vendors / Multi-Vendors
# Open-source Drivers
else
HOOKS+=(systemd keyboard autodetect microcode modconf kms sd-vconsole block sd-encrypt filesystems)
fi
@@ -7314,10 +7223,10 @@ set_vars() {
# ENCRYPTION = 'NO'
elif [[ "${encrypt}" == "no" ]]; then
# HOOKS SETUP
# Nvidia Vendor
if [[ "${vendor}" == "Nvidia" ]]; then
# Nvidia Proprietary Driver
if [[ "${nvdprop}" == "y" ]]; then
HOOKS+=(systemd autodetect microcode modconf keyboard sd-vconsole block filesystems)
# Other Vendors / Multi-Vendors
# Open-source Drivers
else
HOOKS+=(systemd autodetect microcode modconf kms keyboard sd-vconsole block filesystems)
fi
@@ -7333,10 +7242,10 @@ set_vars() {
fi
fi
#--------------------------------------------------------------------------------------------------
# GFX CONFIGURATION = 'YES'
if [[ "${gfxconf}" == "y" ]]; then
# GFX CONFIGURATION
# Nvidia
if [[ "${vendor}" == "Nvidia" || "${vendors}" =~ "Nvidia" ]]; then
if [[ "${nvdprop}" == "y" ]]; then
MODULES+=(nvidia nvidia_modeset nvidia_uvm nvidia_drm)
gfx_bootopts+=(nvidia.NVreg_UsePageAttributeTable=1)
@@ -7364,7 +7273,6 @@ set_vars() {
gfx_bootopts+=(amdgpu.dc=1 radeon.cik_support=0 amdgpu.cik_support=1)
fi
fi
fi
#--------------------------------------------------------------------------------------------------
# MAIN KERNEL PARAMETERS
if [[ -n "${gfx_bootopts[*]}" ]]; then
@@ -7398,7 +7306,7 @@ chroot_conf() {
${magenta}###${nc}--------------------------------${magenta}[ ${bwhite}Chroot & Configure System${nc} ${magenta}]${nc}--------------------------------${magenta}###${nc}
"
# All Desktop Configuration:
# Desktops Configuration:
if [[ "${desktop}" != "12" ]]; then
cnfg
main_chroot
@@ -7434,16 +7342,14 @@ SLICK
fi
fi
if [[ "${vendor}" != "Virtual Machine" ]]; then
if [[ ! "${desktop}" =~ ^(11|12)$ ]]; then
local stage_prompt="Bluetooth Services Activation"
if arch-chroot /mnt <<-BLUETOOTH > "${void}" 2>&1 2> "${log}" ; then
systemctl enable bluetooth || exit
if [[ "${vendor}" != "Virtual Machine" && "${desktop}" != "11" ]]; then
local stage_prompt="Bluetooth Services Activation"
if arch-chroot /mnt <<-BLUETOOTH > "${void}" 2>&1 2> "${log}" ; then
systemctl enable bluetooth || exit
BLUETOOTH
stage_ok
else
stage_fail
fi
stage_ok
else
stage_fail
fi
fi
@@ -7543,7 +7449,7 @@ CUSTOMSERV
log="Amelia_log.txt"
disks="$(lsblk --nodeps --paths --noheadings --output=name,size,model | cat --number)"
trg=""
vars=(LOCALESET="" SETLOCALE="" lcl_slct="" USERNAME="" kernelnmbr="" fs="" gfxcount="" gfxcard="" intelcount="" intelcards="" nvidiacount="" nvidiacards="" amdcount="" amdcards="" gfxconf="" gfx_conf="" gfx_setup="" vendor="" vendor1="" vendor2="" vendor3="" vendor_slct="" desktop="" terminal="" efi_entr_del="" sanity="" install="" bootldr_pkgs="" devel="" REGDOM="" gfx_bootopts="" btrfs_bootopts="" trim="" swapmode="" homecrypt="" greeter="" greeternmbr="" cust_bootopts="" vmpkgs="" vm_services="" perf_stream="" displaymanager="" wireless_reg="" bitness="" bootloader="" gfx_slct="" espsize="" autoroot="" autoesp="" autoxboot="" autohome="" autoswap="" rootprt="" espprt="" xbootprt="" homeprt="" swapprt="" partok="" instl_drive="" sgdsk_nmbr="" part_mode="" preset="" capacity="" cap_gib="" rootsize="" sgdrive="" cgdrive="" smartpart="" presetpart="" prcnt="" roottype="" stage_prompt="" zram="" zram_bootopts="" xbootloader="" multibooting="" hypervisor="" mkinitcpio_mods="" mkinitcpio_bins="" uki="" ukify="" cng_espmnt="" sep_home="" encr_swap_bootopts="" uefimode="" luks_encrypt="" nrg_plc="" multilib="" nvname="" nogsp="" luks_root="" luks_swap="" luks_home="" installation="" kill_watchdog="" oomd="" setrescue="" lowlat="" vendors="" dev="" web="" web_pkg="" web_aur="" web_slct="" printer="" print_pkgs="" shellnmbr="" shell="" shellname="" shellname2="" shell_pkgs="" genoptm="" set_optm="" ask_param="" desk_setup="" set_optm_slct="" irqbalance="" thermald="" rngd="" rtkit="" tlp="" CRYPTPASS="" CRYPTPASS2="" askoptm="" gptslct="" gptok="" gptabort="")
vars=(LOCALESET="" SETLOCALE="" lcl_slct="" USERNAME="" kernelnmbr="" fs="" gfxcount="" gfxcard="" intelcount="" intelcards="" nvidiacount="" nvidiacards="" amdcount="" amdcards="" vendor="" vendors="" desktop="" terminal="" efi_entr_del="" sanity="" install="" bootldr_pkgs="" devel="" REGDOM="" gfx_bootopts="" btrfs_bootopts="" trim="" swapmode="" homecrypt="" greeter="" greeternmbr="" cust_bootopts="" vmpkgs="" vm_services="" perf_stream="" displaymanager="" wireless_reg="" bitness="" bootloader="" gfx_slct="" espsize="" autoroot="" autoesp="" autoxboot="" autohome="" autoswap="" rootprt="" espprt="" xbootprt="" homeprt="" swapprt="" partok="" instl_drive="" sgdsk_nmbr="" part_mode="" preset="" capacity="" cap_gib="" rootsize="" sgdrive="" cgdrive="" smartpart="" presetpart="" prcnt="" roottype="" stage_prompt="" zram="" zram_bootopts="" xbootloader="" multibooting="" hypervisor="" mkinitcpio_mods="" mkinitcpio_bins="" uki="" ukify="" cng_espmnt="" sep_home="" encr_swap_bootopts="" uefimode="" luks_encrypt="" nrg_plc="" multilib="" nvname="" nogsp="" luks_root="" luks_swap="" luks_home="" installation="" kill_watchdog="" oomd="" setrescue="" lowlat="" dev="" web="" web_pkg="" web_aur="" web_slct="" printer="" print_pkgs="" shellnmbr="" shell="" shellname="" shellname2="" shell_pkgs="" genoptm="" set_optm="" ask_param="" desk_setup="" set_optm_slct="" irqbalance="" thermald="" rngd="" rtkit="" tlp="" CRYPTPASS="" CRYPTPASS2="" askoptm="" gptslct="" gptok="" gptabort="" nvdprop="" nowarning="")
export "${vars[@]}"
sleep 0.2
CYANBG "************************************************************************************************* "