From fb2731d62b08881c70da24985d1e9ca93ce48ffa Mon Sep 17 00:00:00 2001 From: Stephan Raabe Date: Mon, 24 Jun 2024 17:23:17 +0200 Subject: [PATCH] Updates --- .install/displaymanager.sh | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/.install/displaymanager.sh b/.install/displaymanager.sh index 2b0b56f..8efb762 100755 --- a/.install/displaymanager.sh +++ b/.install/displaymanager.sh @@ -63,10 +63,15 @@ if [ -z "${dmsel}" ] ;then fi if [ "$dmsel" == "Install sddm and theme" ] ;then + if [ -d /usr/share/sddm/themes/sugar-candy/ ] ;then + rm -rf /usr/share/sddm/themes/sugar-candy/ + echo ":: Sugar Candy folder removed" + fi + disman=0 # Try to force the installation of sddm echo ":: Install sddm" - yay -S --noconfirm sddm --ask 4 + yay -S --noconfirm sddm sddm-sugar-candy-git --ask 4 # Enable sddm if [ -f /etc/systemd/system/display-manager.service ]; then @@ -74,6 +79,26 @@ if [ "$dmsel" == "Install sddm and theme" ] ;then fi sudo systemctl enable sddm.service + if [ ! -d /etc/sddm.conf.d/ ]; then + sudo mkdir /etc/sddm.conf.d + echo "Folder /etc/sddm.conf.d created." + fi + + sudo cp sddm/sddm.conf /etc/sddm.conf.d/ + echo "File /etc/sddm.conf.d/sddm.conf updated." + + if [ -f /usr/share/sddm/themes/sugar-candy/theme.conf ]; then + + # Cache file for holding the current wallpaper + sudo cp wallpapers/default.jpg /usr/share/sddm/themes/sugar-candy/Backgrounds/current_wallpaper.jpg + echo "Default wallpaper copied into /usr/share/sddm/themes/sugar-candy/Backgrounds/" + + sudo cp sddm/theme.conf /usr/share/sddm/themes/sugar-candy/ + sudo sed -i 's/CURRENTWALLPAPER/'"current_wallpaper.jpg"'/' /usr/share/sddm/themes/sugar-candy/theme.conf + echo "File theme.conf updated in /usr/share/sddm/themes/sugar-candy/" + + fi + elif [ "$dmsel" == "Deactivate current display manager" ] ;then sudo rm /etc/systemd/system/display-manager.service