diff --git a/README.md b/README.md index 4df3753..44bab41 100644 --- a/README.md +++ b/README.md @@ -175,7 +175,8 @@ source ~/.zshrc > DO NOT cd into install-scripts directory as script will most likely to fail #### 🛣️ Roadmap: -- [ ] show a progress bar in downloading and compiling part +- [ ] show a progress bar in downloading and compiling part when installing outside AUR or official repo +- [ ] When preset.sh is used, it still asked whether I want thunar to be default manager or not #### ❗ some known issues for nvidia - reports from members of my discord, states that some users of nvidia are getting stuck on sddm login. credit to @Kenni Fix stated was diff --git a/install-scripts/Global_functions.sh b/install-scripts/Global_functions.sh index c72261b..60339a1 100755 --- a/install-scripts/Global_functions.sh +++ b/install-scripts/Global_functions.sh @@ -38,12 +38,12 @@ show_progress() { while ps -p $pid &> /dev/null; do printf "\r${NOTE} Installing ${YELLOW}%s${RESET} %s" "$package_name" "${spin_chars[i]}" - i=$(( (i + 1) % 10 )) # Cycle through 10 animation frames - sleep 0.3 # Slower animation + i=$(( (i + 1) % 10 )) + sleep 0.3 done printf "\r${NOTE} Installing ${YELLOW}%s${RESET} ... Done!%-20s\n" "$package_name" "" - tput cnorm # Show cursor again + tput cnorm } diff --git a/install-scripts/thunar.sh b/install-scripts/thunar.sh index 033f735..34c9a64 100755 --- a/install-scripts/thunar.sh +++ b/install-scripts/thunar.sh @@ -39,17 +39,26 @@ printf "${NOTE} Installing ${BLUE}Thunar${RESET} Packages...\n\n" printf "\n%.0s" {1..2} # confirm if wanted to set as default -read -n1 -rep "${CAT} set ${MAGENTA}Thunar${RESET} as the default file manager? (y/n): " thundefault +while true; do + read -n1 -rep "${CAT} set ${MAGENTA}Thunar${RESET} as the default file manager? (y/n): " thundefault + case $thundefault in + [Yy]) + xdg-mime default thunar.desktop inode/directory + xdg-mime default thunar.desktop application/x-wayland-gnome-saved-search + echo "${OK} Thunar has been set as the default file manager." | tee -a "$LOG" + break + ;; + [Nn]) + echo "${NOTE} you chose not to set Thunar as the default file manager." | tee -a "$LOG" + break + ;; + *) + echo "Invalid input. Please enter 'y' or 'n'." + ;; + esac +done -if [[ "$thundefault" == ^[Yy]$ ]]; then - xdg-mime default thunar.desktop inode/directory - xdg-mime default thunar.desktop application/x-wayland-gnome-saved-search - echo "${OK} Thunar has been set as the default file manager." 2>&1 | tee -a "$LOG" -else - echo "${NOTE} you choose not to set Thunar as default file manager." 2>&1 | tee -a "$LOG" -fi - -printf "\n" +printf "\n%.0s" {1..1} # Check for existing configs and copy if does not exist for DIR1 in gtk-3.0 Thunar xfce4; do