Change: 'Minimal Gnome'/'Minimal Plasma' setups > Enable syntax highlighting for 'nano' package.

Change: A few changes have been made to 'mkinitcpiod.conf' drop-in file, on how/which graphics modules is loading,
since 'kms' hook automates a lot of this process.
This commit is contained in:
Jane Doe 2024-11-16 15:48:14 +00:00
parent 65a89cd51f
commit 886bae9589

View file

@ -2,7 +2,7 @@
# Amelia Installer # Amelia Installer
# https://gitlab.com/prism7/archery # https://gitlab.com/prism7/archery
# Version: 8.0.8 # Version: 8.0.9
set -euo pipefail set -euo pipefail
################################################################################################### ###################################################################################################
@ -3022,7 +3022,7 @@ ${multi_root}
if [[ "${autoroot}" == "y" ]]; then if [[ "${autoroot}" == "y" ]]; then
root_dev="${root_comply}" root_dev="${root_comply}"
multiroot_opts="root=PARTUUID=$(blkid -s PARTUUID -o value "${root_dev}") " multiroot_bootopts="root=PARTUUID=$(blkid -s PARTUUID -o value "${root_dev}") "
elif [[ "${autoroot}" == "n" ]]; then elif [[ "${autoroot}" == "n" ]]; then
stage_fail stage_fail
else else
@ -5695,7 +5695,7 @@ set_vars() {
encr_root_dev="/dev/mapper/${ENCROOT}" encr_root_dev="/dev/mapper/${ENCROOT}"
# Encrypted Root Options # Encrypted Root Options
encr_root_opts="rd.luks.name=$(blkid -s UUID -o value "${root_dev}")=${ENCROOT}" encr_root_opts="rd.luks.name=$(blkid -s UUID -o value "${root_dev}")=${ENCROOT}"
# Encrypted Kernel Boot Options # Encryption Kernel Parameters
encr_root_bootopts="${encr_root_opts} root=${encr_root_dev} " encr_root_bootopts="${encr_root_opts} root=${encr_root_dev} "
### Encrypted Swap Setup ### Encrypted Swap Setup
@ -5703,7 +5703,7 @@ set_vars() {
if [[ "${swapmode}" == "1" ]]; then if [[ "${swapmode}" == "1" ]]; then
# Encrypted Swap Partition Options # Encrypted Swap Partition Options
encr_swap_opts="rd.luks.name=$(blkid -s UUID -o value "${swap_dev}")=swap" encr_swap_opts="rd.luks.name=$(blkid -s UUID -o value "${swap_dev}")=swap"
# Encrypted Swap Partition Kernel Main Boot Options # Encrypted Swap Kernel Parameters
encr_swap_bootopts="resume=/dev/mapper/swap ${encr_swap_opts} " encr_swap_bootopts="resume=/dev/mapper/swap ${encr_swap_opts} "
## Encrypted Swapfile ## Encrypted Swapfile
elif [[ "${swapmode}" == "2" ]]; then elif [[ "${swapmode}" == "2" ]]; then
@ -5714,15 +5714,15 @@ set_vars() {
elif [[ "${fs}" == "2" ]]; then elif [[ "${fs}" == "2" ]]; then
offst="$(btrfs inspect-internal map-swapfile -r /mnt/swap/swapfile)" offst="$(btrfs inspect-internal map-swapfile -r /mnt/swap/swapfile)"
fi fi
# Encrypted Swapfile Kernel Boot Options # Encrypted Swapfile Kernel Parameters
encr_swap_bootopts="resume=${encr_root_dev} resume_offset=${offst} " encr_swap_bootopts="resume=${encr_root_dev} resume_offset=${offst} "
## Zram Swap ## Zram Swap
elif [[ "${swapmode}" == "3" ]]; then elif [[ "${swapmode}" == "3" ]]; then
# Zram Swap Kernel Boot Options # Zram Swap Kernel Parameters
zram_bootopts="zswap.enabled=0 " zram_bootopts="zswap.enabled=0 "
## No Swap ## No Swap
elif [[ "${swapmode}" == "4" ]]; then elif [[ "${swapmode}" == "4" ]]; then
# No Swap Kernel Boot Options # No Swap Kernel Parameters
encr_swap_bootopts="" encr_swap_bootopts=""
fi fi
@ -5732,51 +5732,50 @@ set_vars() {
# Intel # Intel
if [[ "${vendor}" == "Intel" ]]; then if [[ "${vendor}" == "Intel" ]]; then
# Mkinitcpio Modules (Encryption) # Mkinitcpio Modules (Encryption)
mkinitcpio_mods="MODULES=(i915 ${fs_mod})" mkinitcpio_mods="MODULES=(${fs_mod})"
# Mkinitcpio Hooks (Encryption) # Mkinitcpio Hooks (Encryption)
mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf kms sd-vconsole block sd-encrypt filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf kms sd-vconsole block sd-encrypt filesystems fsck)"
# Nvidia # Nvidia
elif [[ "${vendor}" == "Nvidia" ]]; then elif [[ "${vendor}" == "Nvidia" ]]; then
# Mkinitcpio Modules (Encryption) [Early Nvidia KMS] # Mkinitcpio Modules (Encryption) [Nvidia KMS]
mkinitcpio_mods="MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm ${fs_mod})" mkinitcpio_mods="MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm ${fs_mod})"
# Mkinitcpio Hooks (Encryption) # Mkinitcpio Hooks (Encryption)
mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf sd-vconsole block sd-encrypt filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf sd-vconsole block sd-encrypt filesystems fsck)"
# Graphics Kernel Boot Options # Graphics Kernel Parameters
vga_bootopts="nvidia.NVreg_UsePageAttributeTable=1 " vga_bootopts="nvidia.NVreg_UsePageAttributeTable=1 "
# Amd # Amd
elif [[ "${vendor}" == "AMD" ]]; then elif [[ "${vendor}" == "AMD" ]]; then
# Mkinitcpio Modules (Encryption)
mkinitcpio_mods="MODULES=(amdgpu radeon ${fs_mod})"
# Mkinitcpio Hooks (Encryption) # Mkinitcpio Hooks (Encryption)
mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf kms sd-vconsole block sd-encrypt filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf kms sd-vconsole block sd-encrypt filesystems fsck)"
# 'Southern Islands' support # 'Southern Islands' support
if [[ "${islands}" == "1" ]]; then if [[ "${islands}" == "1" ]]; then
# Graphics Kernel Boot Options # Mkinitcpio Modules (Encryption)
mkinitcpio_mods="MODULES=(amdgpu ${fs_mod})"
# Graphics Kernel Parameters
vga_bootopts="radeon.si_support=0 amdgpu.si_support=1 amdgpu.dc=1 " vga_bootopts="radeon.si_support=0 amdgpu.si_support=1 amdgpu.dc=1 "
# 'Sea Islands' support # 'Sea Islands' support
elif [[ "${islands}" == "2" ]]; then elif [[ "${islands}" == "2" ]]; then
# Graphics Kernel Boot Options # Mkinitcpio Modules (Encryption)
mkinitcpio_mods="MODULES=(amdgpu ${fs_mod})"
# Graphics Kernel Parameters
vga_bootopts="radeon.cik_support=0 amdgpu.cik_support=1 amdgpu.dc=1 " vga_bootopts="radeon.cik_support=0 amdgpu.cik_support=1 amdgpu.dc=1 "
elif [[ -z "${islands}" ]]; then elif [[ -z "${islands}" ]]; then
# Graphics Kernel Boot Options # Mkinitcpio Modules (Encryption)
mkinitcpio_mods="MODULES=(${fs_mod})"
# Graphics Kernel Parameters
vga_bootopts="amdgpu.dc=1 " vga_bootopts="amdgpu.dc=1 "
fi fi
fi fi
## Configuration = 'No' ## Configuration = 'No'
elif [[ "${vgaconf}" == "n" ]]; then elif [[ "${vgaconf}" == "n" ]]; then
# Nvidia # Mkinitcpio Modules (Encryption)
if [[ "${vendor}" == "Nvidia" ]]; then mkinitcpio_mods="MODULES=(${fs_mod})"
# Mkinitcpio Modules (Encryption)
mkinitcpio_mods="MODULES=(${fs_mod} nouveau)"
# Other Vendors
else
# Mkinitcpio Modules (Encryption)
mkinitcpio_mods="MODULES=(${fs_mod})"
fi
# Mkinitcpio Hooks (Encryption) # Mkinitcpio Hooks (Encryption)
mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf kms sd-vconsole block sd-encrypt filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd keyboard autodetect microcode modconf kms sd-vconsole block sd-encrypt filesystems fsck)"
# Graphics Kernel Parameters
vga_bootopts="amdgpu.dc=1 "
fi fi
### Kernel Boot Options (Encryption) ### Kernel Parameters (Encryption)
boot_opts="${encr_root_bootopts}${encr_swap_bootopts}${vga_bootopts}${cust_bootopts}${btrfs_bootopts}${zram_bootopts}" boot_opts="${encr_root_bootopts}${encr_swap_bootopts}${vga_bootopts}${cust_bootopts}${btrfs_bootopts}${zram_bootopts}"
#------------------------------------------------------------------------------------------------------------- #-------------------------------------------------------------------------------------------------------------
@ -5785,7 +5784,7 @@ set_vars() {
### Swap Setup ### Swap Setup
## Zram Swap ## Zram Swap
if [[ "${swapmode}" == "3" ]]; then if [[ "${swapmode}" == "3" ]]; then
# Zram Swap Kernel Boot Options # Zram Swap Kernel Parameters
zram_bootopts="zswap.enabled=0 " zram_bootopts="zswap.enabled=0 "
fi fi
### Graphics Setup ### Graphics Setup
@ -5794,59 +5793,57 @@ set_vars() {
# Intel # Intel
if [[ "${vendor}" == "Intel" ]]; then if [[ "${vendor}" == "Intel" ]]; then
# Mkinitcpio Modules # Mkinitcpio Modules
mkinitcpio_mods="MODULES=(i915)" mkinitcpio_mods="MODULES=()"
# Mkinitcpio Hooks # Mkinitcpio Hooks
mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf kms keyboard sd-vconsole block filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf kms keyboard sd-vconsole block filesystems fsck)"
# Nvidia # Nvidia
elif [[ "${vendor}" == "Nvidia" ]]; then elif [[ "${vendor}" == "Nvidia" ]]; then
# Mkinitcpio Modules [Early Nvidia KMS] # Mkinitcpio Modules [Nvidia KMS]
mkinitcpio_mods="MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm)" mkinitcpio_mods="MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm)"
# Mkinitcpio Hooks # Mkinitcpio Hooks
mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf keyboard sd-vconsole block filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf keyboard sd-vconsole block filesystems fsck)"
# Graphics Kernel Boot Options # Graphics Kernel Parameters
vga_bootopts="nvidia.NVreg_UsePageAttributeTable=1 " vga_bootopts="nvidia.NVreg_UsePageAttributeTable=1 "
# Amd # Amd
elif [[ "${vendor}" == "AMD" ]]; then elif [[ "${vendor}" == "AMD" ]]; then
# Mkinitcpio Modules
mkinitcpio_mods="MODULES=(amdgpu radeon)"
# Mkinitcpio Hooks # Mkinitcpio Hooks
mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf kms keyboard sd-vconsole block filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf kms keyboard sd-vconsole block filesystems fsck)"
# 'Southern Islands' support # 'Southern Islands' support
if [[ "${islands}" == "1" ]]; then if [[ "${islands}" == "1" ]]; then
# Graphics Kernel Boot Options # Mkinitcpio Modules
mkinitcpio_mods="MODULES=(amdgpu)"
# Graphics Kernel Parameters
vga_bootopts="radeon.si_support=0 amdgpu.si_support=1 amdgpu.dc=1 " vga_bootopts="radeon.si_support=0 amdgpu.si_support=1 amdgpu.dc=1 "
# 'Sea Islands' support # 'Sea Islands' support
elif [[ "${islands}" == "2" ]]; then elif [[ "${islands}" == "2" ]]; then
# Graphics Kernel Boot Options # Mkinitcpio Modules
mkinitcpio_mods="MODULES=(amdgpu)"
# Graphics Kernel Parameters
vga_bootopts="radeon.cik_support=0 amdgpu.cik_support=1 amdgpu.dc=1 " vga_bootopts="radeon.cik_support=0 amdgpu.cik_support=1 amdgpu.dc=1 "
elif [[ -z "${islands}" ]]; then elif [[ -z "${islands}" ]]; then
# Graphics Kernel Boot Options # Mkinitcpio Modules
mkinitcpio_mods="MODULES=()"
# Graphics Kernel Parameters
vga_bootopts="amdgpu.dc=1 " vga_bootopts="amdgpu.dc=1 "
fi fi
fi fi
## Configuration = 'No' ## Configuration = 'No'
elif [[ "${vgaconf}" == "n" ]]; then elif [[ "${vgaconf}" == "n" ]]; then
# Nvidia # Mkinitcpio Modules
if [[ "${vendor}" == "Nvidia" ]]; then mkinitcpio_mods="MODULES=()"
# Mkinitcpio Modules
mkinitcpio_mods="MODULES=(nouveau)"
# Other Vendors
else
# Mkinitcpio Modules
mkinitcpio_mods="MODULES=()"
fi
# Mkinitcpio Hooks # Mkinitcpio Hooks
mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf kms keyboard sd-vconsole block filesystems fsck)" mkinitcpio_hooks="HOOKS=(systemd autodetect microcode modconf kms keyboard sd-vconsole block filesystems fsck)"
# Graphics Kernel Parameters
vga_bootopts="amdgpu.dc=1 "
fi fi
if [[ "${autoroot}" == "y" ]]; then if [[ "${autoroot}" == "y" ]]; then
### Kernel Boot Options [Multi-Root Disk] (No Encryption) ### Multi-Root Disk Kernel Parameters (No Encryption)
boot_opts="${multiroot_opts}${vga_bootopts}${cust_bootopts}${btrfs_bootopts}${zram_bootopts}" boot_opts="${multiroot_bootopts}${vga_bootopts}${cust_bootopts}${btrfs_bootopts}${zram_bootopts}"
else else
### Kernel Boot Options [Single Root Disk] (No Encryption) ### Single-Root Disk Kernel Parameters (No Encryption)
boot_opts="${vga_bootopts}${cust_bootopts}${btrfs_bootopts}${zram_bootopts}" boot_opts="${vga_bootopts}${cust_bootopts}${btrfs_bootopts}${zram_bootopts}"
fi fi
fi fi
} }
################################################################################################### ###################################################################################################
@ -6141,6 +6138,7 @@ USER
sed -i "/# set linenumbers/"'s/^#//' /etc/nanorc || exit sed -i "/# set linenumbers/"'s/^#//' /etc/nanorc || exit
sed -i "/# set minibar/"'s/^#//' /etc/nanorc || exit sed -i "/# set minibar/"'s/^#//' /etc/nanorc || exit
sed -i "/# set mouse/"'s/^#//' /etc/nanorc || exit sed -i "/# set mouse/"'s/^#//' /etc/nanorc || exit
echo " include /usr/share/nano/*.nanorc" | tee -a /etc/nanorc || exit
echo tcp_bbr | tee /etc/modules-load.d/modulesd.conf || exit echo tcp_bbr | tee /etc/modules-load.d/modulesd.conf || exit
cat <<-SUPPLICANT > /etc/wpa_supplicant/wpa_supplicant.conf || exit cat <<-SUPPLICANT > /etc/wpa_supplicant/wpa_supplicant.conf || exit
country=${REGDOM} country=${REGDOM}