diff options
Diffstat (limited to 'config/hypr/UserScripts')
| -rwxr-xr-x | config/hypr/UserScripts/RofiBeats.sh | 37 | ||||
| -rwxr-xr-x | config/hypr/UserScripts/WallpaperSelect.sh | 5 |
2 files changed, 17 insertions, 25 deletions
diff --git a/config/hypr/UserScripts/RofiBeats.sh b/config/hypr/UserScripts/RofiBeats.sh index 7a7ac3f5..aa9f62e8 100755 --- a/config/hypr/UserScripts/RofiBeats.sh +++ b/config/hypr/UserScripts/RofiBeats.sh @@ -10,18 +10,18 @@ iDIR="$HOME/.config/swaync/icons" # Online Stations. Edit as required declare -A online_music=( - ["AfroBeatz 2024 🎧"]="https://www.youtube.com/watch?v=7uB-Eh9XVZQ" - ["Lofi Girl ☕️🎶"]="https://play.streamafrica.net/lofiradio" - ["Easy Rock 96.3 FM 📻🎶"]="https://radio-stations-philippines.com/easy-rock" - ["Wish 107.5 FM 📻🎶"]="https://radio-stations-philippines.com/dwnu-1075-wish" - ["Wish 107.5 YT Pinoy HipHop 🎻🎶"]="https://youtube.com/playlist?list=PLkrzfEDjeYJnmgMYwCKid4XIFqUKBVWEs&si=vahW_noh4UDJ5d37" - ["Top Youtube Music 2023 ☕️🎶"]="https://youtube.com/playlist?list=PLDIoUOhQQPlXr63I_vwF9GD8sAKh77dWU&si=y7qNeEVFNgA-XxKy" - ["Wish 107.5 YT Wishclusives ☕️🎶"]="https://youtube.com/playlist?list=PLkrzfEDjeYJn5B22H9HOWP3Kxxs-DkPSM&si=d_Ld2OKhGvpH48WO" - ["Chillhop ☕️🎶"]="http://stream.zeno.fm/fyn8eh3h5f8uv" - ["SmoothChill ☕️🎶"]="https://media-ssl.musicradio.com/SmoothChill" - ["Relaxing Music ☕️🎶"]="https://youtube.com/playlist?list=PLMIbmfP_9vb8BCxRoraJpoo4q1yMFg4CE" - ["Youtube Remix 📻🎶"]="https://youtube.com/playlist?list=PLeqTkIUlrZXlSNn3tcXAa-zbo95j0iN-0" - ["Korean Drama OST 📻🎶"]="https://youtube.com/playlist?list=PLUge_o9AIFp4HuA-A3e3ZqENh63LuRRlQ" + ["Lofi Girl Radio ☕️🎶"]="https://play.streamafrica.net/lofiradio" + ["FM - Easy Rock 96.3 📻🎶"]="https://radio-stations-philippines.com/easy-rock" + ["FM - WRock - CEBU 96.3 📻🎶"]="https://onlineradio.ph/126-96-3-wrock.html" + ["YT - Wish 107.5 YT Pinoy HipHop 🎻🎶"]="https://youtube.com/playlist?list=PLkrzfEDjeYJnmgMYwCKid4XIFqUKBVWEs&si=vahW_noh4UDJ5d37" + ["YT - Top Youtube Music 2023 ☕️🎶"]="https://youtube.com/playlist?list=PLDIoUOhQQPlXr63I_vwF9GD8sAKh77dWU&si=y7qNeEVFNgA-XxKy" + ["YT - Wish 107.5 YT Wishclusives ☕️🎶"]="https://youtube.com/playlist?list=PLkrzfEDjeYJn5B22H9HOWP3Kxxs-DkPSM&si=d_Ld2OKhGvpH48WO" + ["Chillhop Radio ☕️🎶"]="http://stream.zeno.fm/fyn8eh3h5f8uv" + ["FM - Fresh Philippines ☕️🎶"]="https://onlineradio.ph/553-fresh-fm.html" + ["YT - Relaxing Music ☕️🎶"]="https://youtube.com/playlist?list=PLMIbmfP_9vb8BCxRoraJpoo4q1yMFg4CE" + ["YT - Youtube Remix 📻🎶"]="https://youtube.com/playlist?list=PLeqTkIUlrZXlSNn3tcXAa-zbo95j0iN-0" + ["YT - Korean Drama OST 📻🎶"]="https://youtube.com/playlist?list=PLUge_o9AIFp4HuA-A3e3ZqENh63LuRRlQ" + ["YT - AfroBeatz 2024 🎧"]="https://www.youtube.com/watch?v=7uB-Eh9XVZQ" ) # Populate local_music array with files from music directory and subdirectories @@ -56,16 +56,9 @@ play_local_music() { notification "$choice" - # For some reason wont start playlist at 0 - if [[ $i -eq 0 ]]; then - # Play the selected local music file using mpv - mpv --loop-playlist --vid=no "$mDIR/$choice" - - else - file=$i - # Play the selected local music file using mpv - mpv --playlist-start="$file" --loop-playlist --vid=no "$mDIR/$choice" - fi + # Play the selected local music file using mpv + mpv --playlist-start="$i" --loop-playlist --vid=no "${local_music[@]}" + break fi done diff --git a/config/hypr/UserScripts/WallpaperSelect.sh b/config/hypr/UserScripts/WallpaperSelect.sh index 06859112..d2ca7c28 100755 --- a/config/hypr/UserScripts/WallpaperSelect.sh +++ b/config/hypr/UserScripts/WallpaperSelect.sh @@ -33,8 +33,8 @@ rofi_command="rofi -i -show -dmenu -config ~/.config/rofi/config-wallpaper.rasi" # Sorting Wallpapers menu() { sorted_options=($(printf '%s\n' "${PICS[@]}" | sort)) - # Place ". random" at the beginning - printf "%s\n" "$RANDOM_PIC_NAME" + # Place ". random" at the beginning with the random picture as an icon + printf "%s\x00icon\x1f%s\n" "$RANDOM_PIC_NAME" "$RANDOM_PIC" for pic_path in "${sorted_options[@]}"; do pic_name=$(basename "$pic_path") # Displaying .gif to indicate animated images @@ -59,7 +59,6 @@ main() { # Random choice case if [ "$choice" = "$RANDOM_PIC_NAME" ]; then - RANDOM_PIC="${PICS[$((RANDOM % ${#PICS[@]}))]}" swww img -o $focused_monitor "${RANDOM_PIC}" $SWWW_PARAMS exit 0 fi |
