From a63e7e67bc6589f58bbed9e4c244010bd4b12642 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Sat, 1 Feb 2025 19:09:41 +0900 Subject: some script clean up --- config/hypr/UserScripts/RofiBeats.sh | 6 +++--- config/hypr/UserScripts/WallpaperEffects.sh | 2 +- config/hypr/UserScripts/WallpaperSelect.sh | 3 +-- config/hypr/scripts/RofiSearch.sh | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-) diff --git a/config/hypr/UserScripts/RofiBeats.sh b/config/hypr/UserScripts/RofiBeats.sh index 919eafc3..bb20e2b6 100755 --- a/config/hypr/UserScripts/RofiBeats.sh +++ b/config/hypr/UserScripts/RofiBeats.sh @@ -47,7 +47,7 @@ play_local_music() { populate_local_music # Prompt the user to select a song - choice=$(printf "%s\n" "${filenames[@]}" | rofi -i -dmenu -config ~/.config/rofi/config-rofi-Beats.rasi -p "Local Music") + choice=$(printf "%s\n" "${filenames[@]}" | rofi -i -dmenu -config ~/.config/rofi/config-rofi-Beats.rasi) if [ -z "$choice" ]; then exit 1 @@ -77,7 +77,7 @@ shuffle_local_music() { # Main function for playing online music play_online_music() { - choice=$(printf "%s\n" "${!online_music[@]}" | rofi -i -dmenu -config ~/.config/rofi/config-rofi-Beats.rasi -p "Online Music") + choice=$(printf "%s\n" "${!online_music[@]}" | rofi -i -dmenu -config ~/.config/rofi/config-rofi-Beats.rasi) if [ -z "$choice" ]; then exit 1 @@ -101,7 +101,7 @@ fi # Prompt the user to choose between local and online music -user_choice=$(printf "Play from Online Stations\nPlay from Music Folder\nShuffle Play from Music Folder" | rofi -dmenu -config ~/.config/rofi/config-rofi-Beats-menu.rasi -p "Select music source") +user_choice=$(printf "Play from Online Stations\nPlay from Music Folder\nShuffle Play from Music Folder" | rofi -dmenu -config ~/.config/rofi/config-rofi-Beats-menu.rasi) case "$user_choice" in "Play from Music Folder") diff --git a/config/hypr/UserScripts/WallpaperEffects.sh b/config/hypr/UserScripts/WallpaperEffects.sh index 481489e9..ccb5b744 100755 --- a/config/hypr/UserScripts/WallpaperEffects.sh +++ b/config/hypr/UserScripts/WallpaperEffects.sh @@ -63,7 +63,7 @@ main() { done # Show rofi menu and handle user choice - choice=$(printf "%s\n" "${options[@]}" | LC_COLLATE=C sort | rofi -dmenu -p "Choose effect" -i -config ~/.config/rofi/config-wallpaper-effect.rasi) + choice=$(printf "%s\n" "${options[@]}" | LC_COLLATE=C sort | rofi -dmenu -i -config ~/.config/rofi/config-wallpaper-effect.rasi) # Process user choice if [[ -n "$choice" ]]; then diff --git a/config/hypr/UserScripts/WallpaperSelect.sh b/config/hypr/UserScripts/WallpaperSelect.sh index 5fc1e1a4..7d6b339f 100755 --- a/config/hypr/UserScripts/WallpaperSelect.sh +++ b/config/hypr/UserScripts/WallpaperSelect.sh @@ -106,5 +106,4 @@ wait $! wait $! sleep 2 -"$SCRIPTSDIR/Refresh.sh" - +"$SCRIPTSDIR/Refresh.sh" \ No newline at end of file diff --git a/config/hypr/scripts/RofiSearch.sh b/config/hypr/scripts/RofiSearch.sh index ccc73016..faf07865 100755 --- a/config/hypr/scripts/RofiSearch.sh +++ b/config/hypr/scripts/RofiSearch.sh @@ -13,5 +13,5 @@ if pgrep -x "rofi" >/dev/null; then fi # Open rofi with a dmenu and pass the selected item to xdg-open for Google search -echo "" | rofi -dmenu -config "$rofi_config" -p "Search:" | xargs -I{} xdg-open "https://www.google.com/search?q={}" +echo "" | rofi -dmenu -config "$rofi_config" | xargs -I{} xdg-open "https://www.google.com/search?q={}" -- cgit v1.2.3