From af8f6078cf5bb786f992da53fa868802858186a2 Mon Sep 17 00:00:00 2001 From: "[yuri]" <[yuri.kuit@gmail.com]> Date: Mon, 10 Nov 2025 15:03:28 +0100 Subject: [PATCH] fix deb xfce --- v2/debian-xfce.sh | 42 +++++++++++------------------------------- 1 file changed, 11 insertions(+), 31 deletions(-) diff --git a/v2/debian-xfce.sh b/v2/debian-xfce.sh index 6a97c69..e44ab4a 100755 --- a/v2/debian-xfce.sh +++ b/v2/debian-xfce.sh @@ -78,34 +78,24 @@ enable_graphical_target() { ########################## # Start installation ########################## -color_yellow -echo "Starting XFCE installation..." -color_reset +echo "${YELLOW}Starting XFCE installation...${RESET}" CURRENT_DE="$(detect_de)" CURRENT_DM="$(detect_display_manager)" if [[ -z "$CURRENT_DE" ]]; then - color_cyan - echo "No Desktop Environment detected. Installing XFCE (light setup with SDDM)..." - color_reset + echo "${CYAN}No Desktop Environment detected. Installing XFCE (light setup with SDDM)...${RESET}" install_packages sddm xfce4 xfce4-goodies enable_graphical_target - color_green - echo "XFCE with SDDM installed successfully. You can reboot now to start XFCE." - color_reset + echo "${GREEN}XFCE with SDDM installed successfully. You can reboot now to start XFCE.${RESET}" else - color_cyan - echo "Detected existing Desktop Environment: $CURRENT_DE" - color_reset + echo "${CYAN}Detected existing Desktop Environment: $CURRENT_DE${RESET}" if [[ "$CURRENT_DM" == "lightdm" ]]; then - color_yellow - echo "LightDM is currently active. Replacing with SDDM..." - color_reset + echo "${YELLOW}LightDM is currently active. Replacing with SDDM...${RESET}" sudo systemctl disable lightdm sudo apt purge -y lightdm lightdm-gtk-greeter @@ -114,26 +104,16 @@ else enable_graphical_target - color_green - echo "LightDM removed and replaced with SDDM." - color_reset + echo "${GREEN}LightDM removed and replaced with SDDM.${RESET}" else - color_cyan - echo "Current display manager: ${CURRENT_DM:-none}. Leaving unchanged." - color_reset + echo "${CYAN}Current display manager: ${CURRENT_DM:-none}. Leaving unchanged.${RESET}" fi fi -# Force XFCE X11 session for SDDM +# Force SDDM to use X11 session sudo mkdir -p /etc/sddm.conf.d -sudo tee /etc/sddm.conf.d/override.conf > /dev/null <<'EOF' -[Autologin] -#User=$USER -#Session=xfce.desktop - -[General] -DefaultSession=xfce.desktop -EOF +echo -e "[Autologin]\nSession=xfce.desktop" | sudo tee /etc/sddm.conf.d/10-xfce.conf >/dev/null +echo -e "[General]\nSession=xfce.desktop" | sudo tee /etc/sddm.conf.d/10-xfce-session.conf >/dev/null # End of script -color_green; echo "XFCE / SDDM setup completed."; color_reset \ No newline at end of file +echo "${GREEN}XFCE / SDDM setup completed.${RESET}" \ No newline at end of file