From d096c34be306d9a0e23dff42730defe8126d54d6 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Sun, 9 Feb 2025 10:35:34 +0900 Subject: [PATCH] more robust approach in installing sddm to avoid newbie move --- install-scripts/sddm_theme.sh | 18 ++++++++++++++++++ install.sh | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) diff --git a/install-scripts/sddm_theme.sh b/install-scripts/sddm_theme.sh index 1181623..472d2c9 100755 --- a/install-scripts/sddm_theme.sh +++ b/install-scripts/sddm_theme.sh @@ -60,6 +60,24 @@ if git clone --depth 1 "$source_theme" "$theme_name"; then sudo cp -r assets/sddm.png "/usr/share/sddm/themes/$theme_name/backgrounds/default" 2>&1 | tee -a "$LOG" sudo sed -i 's|^wallpaper=".*"|wallpaper="backgrounds/default"|' "/usr/share/sddm/themes/$theme_name/theme.conf" 2>&1 | tee -a "$LOG" + printf "\n%.0s" {1..1} + printf "${NOTE} copying ${YELLOW}JetBrains Mono Nerd Font${RESET} to ${YELLOW}/usr/local/share/fonts${RESET} .......\n" + printf "${NOTE} necessary for the new SDDM theme to work properly........\n" + + sudo mkdir -p /usr/local/share/fonts/JetBrainsMonoNerd && \ + sudo cp -r "$HOME/.local/share/fonts/JetBrainsMonoNerd" /usr/local/share/fonts/JetBrainsMonoNerd + + if [ $? -eq 0 ]; then + echo "Fonts copied successfully." + else + echo "Failed to copy fonts." + fi + + # Update font cache and log the output + fc-cache -v -f 2>&1 | tee -a "$LOG" + + printf "\n%.0s" {1..1} + echo "${OK} - ${MAGENTA}Additional SDDM Theme${RESET} successfully installed." | tee -a "$LOG" else diff --git a/install.sh b/install.sh index 5e77f4c..029eead 100755 --- a/install.sh +++ b/install.sh @@ -211,7 +211,7 @@ ask_yes_no "-Install & configure ${YELLOW}SDDM${RESET} as login manager?" sddm # check if any known login managers are active when users choose to install sddm if [ "$sddm" == "y" ] || [ "$sddm" == "Y" ]; then # List of services to check - services=("gdm.service" "gdm3.service" "lightdm.service" "xdm.service" "lxdm.service") + services=("gdm.service" "gdm3.service" "lightdm.service" "lxdm.service") # Loop through each service for svc in "${services[@]}"; do