Disable ly display manager, add some more info.

This commit is contained in:
natemaia 2020-05-03 15:52:40 -07:00
parent 2208c3afba
commit fc7ae70f16

View File

@ -7,7 +7,7 @@
# shellcheck disable=SC2086,SC2046,SC2254 # shellcheck disable=SC2086,SC2046,SC2254
VER=2.1.41 VER=2.1.42
# default values { # default values {
@ -461,15 +461,15 @@ select_login()
AUTOLOGIN='' AUTOLOGIN=''
dlg LOGIN_TYPE menu "Login" "\nSelect what kind of login management to use." \ dlg LOGIN_TYPE menu "Login" "\nSelect what kind of login management to use." \
"xinit" "Console login without a display manager" \ "xinit" "Console login with no graphical display manager" \
"ly" "TUI display manager with a ncurses-like interface" \ "lightdm" "Lightweight display manager (deepin and xfce default)" \
"lightdm" "Lightweight display manager with a gtk greeter" \ "gdm" "Gnome display manager (gnome default, go figure)" \
"gdm" "Gnome display manager" \ "sddm" "Simple desktop display manager (plasma default)" || return 1
"sddm" "Simple desktop display manager" || return 1
case $LOGIN_TYPE in case $LOGIN_TYPE in
gdm|sddm) EDIT_FILES[login]="" ;; gdm|sddm)
ly) EDIT_FILES[login]="/etc/ly/config.ini" ;; EDIT_FILES[login]=""
;;
lightdm) lightdm)
LIGHTDM_GREETER='gtk-greeter' LIGHTDM_GREETER='gtk-greeter'
EDIT_FILES[login]="/etc/lightdm/lightdm.conf /etc/lightdm/lightdm-gtk-greeter.conf" EDIT_FILES[login]="/etc/lightdm/lightdm.conf /etc/lightdm/lightdm-gtk-greeter.conf"
@ -495,14 +495,21 @@ select_config()
until [[ $CONFIG_DONE ]]; do until [[ $CONFIG_DONE ]]; do
case $i in case $i in
0) dlg NEWSHELL menu "Shell" "\nChoose which shell to use." \ 0)
dlg NEWSHELL menu "Shell" "\nChoose which shell to use." \
zsh 'A very advanced and programmable command interpreter (shell) for UNIX' \ zsh 'A very advanced and programmable command interpreter (shell) for UNIX' \
bash 'The GNU Bourne Again shell, standard in many GNU/Linux distributions' \ bash 'The GNU Bourne Again shell, standard in many GNU/Linux distributions' \
mksh 'The MirBSD Korn Shell - an enhanced version of the public domain ksh' || return 1 mksh 'The MirBSD Korn Shell - an enhanced version of the public domain ksh' || return 1
;; ;;
1) dlg NEWHOST input "Hostname" "$_hostname" "${DIST,,}" limit || { i=0; continue; } ;; 1)
2) dlg LOCALE menu "Locale" "$_locale" $LOCALES || { i=1; continue; } ;; dlg NEWHOST input "Hostname" "$_hostname" "${DIST,,}" limit || { i=0; continue; }
3) ZONE='' SUBZ='' ;;
2)
dlg LOCALE menu "Locale" "$_locale" $LOCALES || { i=1; continue; }
;;
3)
ZONE='' SUBZ=''
until [[ $ZONE && $SUBZ ]]; do until [[ $ZONE && $SUBZ ]]; do
dlg ZONE menu "Timezone" "$_timez" \ dlg ZONE menu "Timezone" "$_timez" \
America - \ America - \
@ -521,12 +528,15 @@ select_config()
print $3 " - " print $3 " - "
}' /usr/share/zoneinfo/zone.tab | sort) || continue }' /usr/share/zoneinfo/zone.tab | sort) || continue
done done
[[ $ZONE && $SUBZ ]] || { i=2; continue; } ;; [[ $ZONE && $SUBZ ]] || { i=2; continue; }
4) dlg KERNEL menu "Kernel" "\nChoose which kernel to use." \ ;;
4)
dlg KERNEL menu "Kernel" "\nChoose which kernel to use." \
linux 'Vanilla linux kernel and modules, with a few patches applied' \ linux 'Vanilla linux kernel and modules, with a few patches applied' \
linux-lts 'Long-term support (LTS) linux kernel and modules' \ linux-lts 'Long-term support (LTS) linux kernel and modules' \
linux-zen 'A effort of kernel hackers to provide the best kernel for everyday systems' \ linux-zen 'A effort of kernel hackers to provide the best kernel for everyday systems' \
linux-hardened 'A security-focused linux kernel with hardening patches to mitigate exploits' || { i=3; continue; } linux-hardened 'A security-focused linux kernel with hardening patches to mitigate exploits' || { i=3; continue; }
CONFIG_DONE=true CONFIG_DONE=true
;; ;;
esac esac
@ -535,7 +545,7 @@ select_config()
case $NEWSHELL in case $NEWSHELL in
bash) LOGINRC='.bash_profile' ;; bash) LOGINRC='.bash_profile' ;;
zsh) LOGINRC='.zprofile' ;; zsh) LOGINRC='.zprofile' ;;
mksh) LOGINRC='.profile' ;; mksh) LOGINRC='.profile' ;;
esac esac
@ -941,9 +951,15 @@ part_find()
PART_COUNT=$(wc -l <<< "$PARTS") PART_COUNT=$(wc -l <<< "$PARTS")
case "$regexp" in case "$regexp" in
'part|lvm|crypt') [[ $PART_COUNT -lt 1 || ($SYS == 'UEFI' && $PART_COUNT -lt 2) ]] && err="$_errpart" ;; 'part|lvm|crypt')
'part|crypt') (( PART_COUNT < 1 )) && err="$_lvmerr" ;; [[ $PART_COUNT -lt 1 || ($SYS == 'UEFI' && $PART_COUNT -lt 2) ]] && err="$_errpart"
'part|lvm') (( PART_COUNT < 2 )) && err="$_lukserr" ;; ;;
'part|crypt')
(( PART_COUNT < 1 )) && err="$_lvmerr"
;;
'part|lvm')
(( PART_COUNT < 2 )) && err="$_lukserr"
;;
esac esac
if [[ $err ]]; then if [[ $err ]]; then
@ -1707,11 +1723,18 @@ install_bootldr()
# some UEFI firmware requires a generic esp/BOOT/BOOTX64.EFI # some UEFI firmware requires a generic esp/BOOT/BOOTX64.EFI
mkdir -pv "$MNT/boot/EFI/BOOT" mkdir -pv "$MNT/boot/EFI/BOOT"
case "$BOOTLDR" in case "$BOOTLDR" in
grub) cp -fv "$MNT/boot/EFI/$DIST/grubx64.efi" "$MNT/boot/EFI/BOOT/BOOTX64.EFI" ;; grub)
syslinux) cp -rf "$MNT/boot/EFI/syslinux/"* "$MNT/boot/EFI/BOOT/" && cp -f "$MNT/boot/EFI/syslinux/syslinux.efi" "$MNT/boot/EFI/BOOT/BOOTX64.EFI" ;; cp -fv "$MNT/boot/EFI/$DIST/grubx64.efi" "$MNT/boot/EFI/BOOT/BOOTX64.EFI"
;;
syslinux)
cp -rf "$MNT/boot/EFI/syslinux/"* "$MNT/boot/EFI/BOOT/"
cp -f "$MNT/boot/EFI/syslinux/syslinux.efi" "$MNT/boot/EFI/BOOT/BOOTX64.EFI"
;;
refind-efi) refind-efi)
sed -i '/#extra_kernel_version_strings/ c extra_kernel_version_strings linux-hardened,linux-zen,linux-lts,linux' "$MNT/boot/EFI/refind/refind.conf" k="linux-hardened,linux-zen,linux-lts,linux"
cp -fv "$MNT/boot/EFI/refind/refind_x64.efi" "$MNT/boot/EFI/BOOT/BOOTX64.EFI" ;; sed -i "/#extra_kernel_version_strings/ c extra_kernel_version_strings $k" "$MNT/boot/EFI/refind/refind.conf"
cp -fv "$MNT/boot/EFI/refind/refind_x64.efi" "$MNT/boot/EFI/BOOT/BOOTX64.EFI"
;;
esac esac
fi fi
@ -1786,8 +1809,12 @@ install_packages()
if [[ $VM == 'oracle' ]]; then if [[ $VM == 'oracle' ]]; then
case "$KERNEL" in case "$KERNEL" in
linux) chrun "pacman -S virtualbox-guest-utils virtualbox-guest-modules-arch --needed --noconfirm" ;; linux)
*) chrun "pacman -S ${KERNEL}-headers virtualbox-guest-utils virtualbox-guest-modules-dkms --needed --noconfirm" ;; chrun "pacman -S virtualbox-guest-utils virtualbox-guest-modules-arch --needed --noconfirm"
;;
*)
chrun "pacman -S ${KERNEL}-headers virtualbox-guest-utils virtualbox-guest-modules-dkms --needed --noconfirm"
;;
esac esac
fi fi
@ -1998,11 +2025,6 @@ install_background()
# these are called based on which DM is chosen after it is installed # these are called based on which DM is chosen after it is installed
# additional config can be handled here, for now only lightdm and xinit. # additional config can be handled here, for now only lightdm and xinit.
config_ly()
{
: #TODO
}
config_gdm() config_gdm()
{ {
: #TODO : #TODO
@ -2494,9 +2516,9 @@ luks_menu()
"Back" "Return to the main menu" "Back" "Return to the main menu"
case "$choice" in case "$choice" in
"$_luksnew") luks_basic || return 1 ;; "$_luksnew") luks_basic || return 1 ;;
"$_luksopen") luks_open || return 1 ;; "$_luksopen") luks_open || return 1 ;;
"$_luksadv") luks_advanced || return 1 ;; "$_luksadv") luks_advanced || return 1 ;;
esac esac
return 0 return 0
@ -2717,9 +2739,16 @@ live()
pacman -S ${BASE_PKGS[*]} xorg-xinit --needed --noconfirm || die 1 pacman -S ${BASE_PKGS[*]} xorg-xinit --needed --noconfirm || die 1
rm -rf /var/cache/pacman/pkg/* rm -rf /var/cache/pacman/pkg/*
case "$ses" in case "$ses" in
$WM_PKG_SES) pacman -S "$ses" ${WM_PKGS[*]} ${WM_EXT[$ses]} --needed --noconfirm || die 1 ;; $WM_PKG_SES)
$SELF_CONTAINED) pacman -S "$ses" ${WM_EXT[$ses]} --needed --noconfirm || die 1 ;; pacman -S "$ses" ${WM_PKGS[*]} ${WM_EXT[$ses]} --needed --noconfirm || die 1
dwm) { pacman -S git --needed --noconfirm || die 1; }; install_suckless "/root" nochroot ;; ;;
$SELF_CONTAINED)
pacman -S "$ses" ${WM_EXT[$ses]} --needed --noconfirm || die 1
;;
dwm)
pacman -S git --needed --noconfirm || die 1
install_suckless "/root" nochroot
;;
esac esac
rm -rf /var/cache/pacman/pkg/* rm -rf /var/cache/pacman/pkg/*
[[ $VM == 'oracle' ]] && pacman -S virtualbox-guest-utils virtualbox-guest-modules-arch --needed --noconfirm [[ $VM == 'oracle' ]] && pacman -S virtualbox-guest-utils virtualbox-guest-modules-arch --needed --noconfirm
@ -2728,8 +2757,12 @@ live()
cp -rfT /etc/skel /root cp -rfT /etc/skel /root
install_tearfree "/etc/X11/xorg.conf.d" install_tearfree "/etc/X11/xorg.conf.d"
case "$ses" in case "$ses" in
$SELF_CONTAINED) sed -i '/super/d; /nitrogen/d; /picom/d' /root/.xprofile ;; $SELF_CONTAINED)
dwm) sed -i '/super/d; /picom/d' /root/.xprofile ;; sed -i '/super/d; /nitrogen/d; /picom/d' /root/.xprofile
;;
dwm)
sed -i '/super/d; /picom/d' /root/.xprofile
;;
esac esac
rm -f /root/.zlogin rm -f /root/.zlogin
echo -e "pulseaudio &\n(sleep 1; pamixer --unmute --set-volume 50) &" >> /root/.xprofile echo -e "pulseaudio &\n(sleep 1; pamixer --unmute --set-volume 50) &" >> /root/.xprofile