From 9e7b47f1b8dafbfadee3863355b3785384ffe436 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Mon, 27 Nov 2023 12:04:47 +0900 Subject: Here are changes made 1.) Use pywal for dunst colors. However, seems backgrounds are not changing. Perhaps only on OpenSuse? 2.) Deleted preconfigured style for dunst. to align with #1 changes 3.) Rewrite some scripts to align with PywalDunst. 4.) New script created for Dunst-Pywal called PywalDunst.sh 5.) Random wallpaper auto change is not increased timing to change every 15 mins 6.) Some scripts are re-written --- config/hypr/scripts/WallpaperRandom.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'config/hypr/scripts/WallpaperRandom.sh') diff --git a/config/hypr/scripts/WallpaperRandom.sh b/config/hypr/scripts/WallpaperRandom.sh index 13bc5033..35bfcf8a 100755 --- a/config/hypr/scripts/WallpaperRandom.sh +++ b/config/hypr/scripts/WallpaperRandom.sh @@ -2,9 +2,12 @@ # This script will randomly go through the files of a directory, setting it # up as the wallpaper at regular intervals +# +# NOTE: this script uses bash (not POSIX shell) for the RANDOM variable pywal_script=$HOME/.config/hypr/scripts/PywalSwww.sh pywal_refresh=$HOME/.config/hypr/scripts/Refresh.sh +pywal_dunst=$HOME/.config/hypr/scripts/PywalDunst.sh if [[ $# -lt 1 ]] || [[ ! -d $1 ]]; then echo "Usage: @@ -18,7 +21,7 @@ export SWWW_TRANSITION_STEP=2 export SWWW_TRANSITION_TYPE=random # This controls (in seconds) when to switch to the next image -INTERVAL=300 +INTERVAL=600 while true; do find "$1" \ @@ -27,7 +30,7 @@ while true; do done \ | sort -n | cut -d':' -f2- \ | while read -r img; do - swww img "$img" && $pywal_script && $pywal_refresh + swww img "$img" && $pywal_script && $pywal_refresh && $pywal_dunst sleep $INTERVAL done -- cgit v1.2.3 From 816475928f186a6ff4486a3d1138a78ffcffd898 Mon Sep 17 00:00:00 2001 From: JaKooLit Date: Mon, 27 Nov 2023 13:02:18 +0900 Subject: refer to my previous commit message --- config/hypr/configs/Execs.conf | 2 +- config/hypr/scripts/Brightness.sh | 2 +- config/hypr/scripts/Volume.sh | 6 ++---- config/hypr/scripts/WallpaperRandom.sh | 2 +- 4 files changed, 5 insertions(+), 7 deletions(-) (limited to 'config/hypr/scripts/WallpaperRandom.sh') diff --git a/config/hypr/configs/Execs.conf b/config/hypr/configs/Execs.conf index 2cf5946b..478eac27 100644 --- a/config/hypr/configs/Execs.conf +++ b/config/hypr/configs/Execs.conf @@ -10,7 +10,7 @@ exec-once = $HOME/.config/hypr/initial-boot.sh # wallpaper stuff exec-once = swww query || swww init -exec-once = $SwwwRandom $WallpaperPath # random wallpaper switcher every 5 minutes +exec-once = $SwwwRandom $WallpaperPath # random wallpaper switcher every 15 minutes #exec-once = swww query || swww init && swww img $HOME/Pictures/wallpapers/mecha-nostalgia.png # persistent wallpaper # Startup diff --git a/config/hypr/scripts/Brightness.sh b/config/hypr/scripts/Brightness.sh index 72cff898..c5c0b80f 100755 --- a/config/hypr/scripts/Brightness.sh +++ b/config/hypr/scripts/Brightness.sh @@ -26,7 +26,7 @@ get_icon() { # Notify notify_user() { - notify-send -h string:x-dunst-stack-tag:brightness_notif -h int:value:$current -u low -i "$icon" "Brightness : $current%" + dunstify -h string:x-dunst-stack-tag:brightness_notif -h int:value:$current -u low -i "$icon" "Brightness : $current%" } # Change brightness diff --git a/config/hypr/scripts/Volume.sh b/config/hypr/scripts/Volume.sh index c5eab801..a51999df 100755 --- a/config/hypr/scripts/Volume.sh +++ b/config/hypr/scripts/Volume.sh @@ -24,8 +24,7 @@ get_icon() { # Notify notify_user() { -# notify-send -h string:x-canonical-private-synchronous:sys-notify -u normal -i "$(get_icon)" "Volume : $(get_volume) %" - notify-send -h int:value:$(get_volume) -h "string:x-dunst-stack-tag:volume_notif" -u low -i "$(get_icon)" "Volume : $(get_volume) %" + dunstify -h int:value:$(get_volume) -h "string:x-dunst-stack-tag:volume_notif" -u low -i "$(get_icon)" "Volume : $(get_volume) %" } @@ -71,8 +70,7 @@ get_mic_icon() { } # Notify notify_mic_user() { -# notify-send -h string:x-canonical-private-synchronous:sys-notify -u low -i "$(get_mic_icon)" "Mic-Level : $(pamixer --default-source --get-volume) %" - notify-send -h int:value:$(pamixer --default-source --get-volume) -h "string:x-dunst-stack-tag:volume_notif" -u low -i "$(get_mic_icon)" "Mic-Level : $(pamixer --default-source --get-volume) %" + dunstify -h int:value:$(pamixer --default-source --get-volume) -h "string:x-dunst-stack-tag:volume_notif" -u low -i "$(get_mic_icon)" "Mic-Level : $(pamixer --default-source --get-volume) %" } # Increase MIC Volume diff --git a/config/hypr/scripts/WallpaperRandom.sh b/config/hypr/scripts/WallpaperRandom.sh index 35bfcf8a..910093ad 100755 --- a/config/hypr/scripts/WallpaperRandom.sh +++ b/config/hypr/scripts/WallpaperRandom.sh @@ -21,7 +21,7 @@ export SWWW_TRANSITION_STEP=2 export SWWW_TRANSITION_TYPE=random # This controls (in seconds) when to switch to the next image -INTERVAL=600 +INTERVAL=900 while true; do find "$1" \ -- cgit v1.2.3