#!/bin/bash #-------------------------------- # Created by chuanjang(at)gmail(dot)com # Download: wget https://diii.neocities.org/xfce.txt # Usage: # chmod +x xfce.txt # sh xfce.txt # COLORS Reset=$(tput sgr0) # Regular Colors Red=$(tput setaf 1) Green=$(tput setaf 2) Yellow=$(tput setaf 3) Purple=$(tput setaf 5) Cyan=$(tput setaf 6) print_line() { #{{{ printf "%$(tput cols)s\n"|tr ' ' '-' } #}}} read_input_text() { #{{{ read -p "$1 [y/N]: " OPTION OPTION=`echo "$OPTION" | tr '[:upper:]' '[:lower:]'` } #}}} pause_function() { #{{{ print_line read -e -sn 1 -p "Press enter to continue..." } #}}} sudo sh -c "pacman -Syu --noconfirm" #For Nvidia #sudo sh -c "pacman -S nvidia nvidia-settings --noconfirm" #Xorg and Xfce desktop sudo sh -c "pacman -S --noconfirm xorg-server xfce4" echo -e "\n\n" print_line read_input_text "Install ${Yellow}Pxfce4-goodies${Reset}: " if [[ $OPTION == y ]]; then sudo sh -c "pacman -S xfce4-goodies --noconfirm" fi echo -e "\n\nInstall ${Cyan}PulseAudio${Reset}" #Install additional components sudo sh -c "pacman -S --noconfirm network-manager-applet gvfs pulseaudio pulseaudio-alsa pavucontrol" #Install applications sudo sh -c "pacman -S --noconfirm firefox l3afpad" #Display Manager sudo sh -c "pacman -S --noconfirm sddm" #Autologin sudo sh -c "mkdir -p /etc/sddm.conf.d" sudo sh -c "echo '[Autologin]' >> /etc/sddm.conf.d/autologin.conf" sudo sh -c "echo 'User=$USER' >> /etc/sddm.conf.d/autologin.conf" sudo sh -c "echo 'Session=xfce' >> /etc/sddm.conf.d/autologin.conf" sudo sh -c "echo '[General]' >> /etc/sddm.conf" sudo sh -c "echo 'Numlock=on' >> /etc/sddm.conf" sudo sh -c "systemctl enable sddm" echo -e "\n${Cyan}SDDM${Reset} installed and set ${Green}Autologin${Reset} & ${Green}NumLock${Reset}\n" pause_function wget https://diii.neocities.org/localize.txt chmod +x localize.txt sh localize.txt rm -rf localize.txt echo -e "\nMust reboot to enable setting." pause_function reboot exit 0