aboutsummaryrefslogtreecommitdiffstats
path: root/config/hypr/UserScripts/WallpaperAutoChange.sh
diff options
context:
space:
mode:
authorJa.KooLit <jimmielovejay@gmail.com>2024-05-09 23:12:25 +0900
committerGitHub <noreply@github.com>2024-05-09 23:12:25 +0900
commita3994cc8edd41fa42dfe1a6f22754dcdcc3d1e51 (patch)
treed7c3a5611522f5c485614fbd62334a28e5b74253 /config/hypr/UserScripts/WallpaperAutoChange.sh
parent472661662b29ec932f017e44a36a63b0dc61ac38 (diff)
parent42430346d8e9bd491f349a12e28f2d8299ae601b (diff)
Merge branch 'development' into main
Diffstat (limited to 'config/hypr/UserScripts/WallpaperAutoChange.sh')
-rwxr-xr-xconfig/hypr/UserScripts/WallpaperAutoChange.sh4
1 files changed, 3 insertions, 1 deletions
diff --git a/config/hypr/UserScripts/WallpaperAutoChange.sh b/config/hypr/UserScripts/WallpaperAutoChange.sh
index e52b7e90..9e0e1cbe 100755
--- a/config/hypr/UserScripts/WallpaperAutoChange.sh
+++ b/config/hypr/UserScripts/WallpaperAutoChange.sh
@@ -9,6 +9,8 @@
pywal_refresh=$HOME/.config/hypr/scripts/RefreshNoWaybar.sh
+focused_monitor=$(hyprctl monitors | awk '/^Monitor/{name=$2} /focused: yes/{print name}')
+
if [[ $# -lt 1 ]] || [[ ! -d $1 ]]; then
echo "Usage:
$0 <dir containing images>"
@@ -29,7 +31,7 @@ while true; do
done \
| sort -n | cut -d':' -f2- \
| while read -r img; do
- swww img "$img"
+ swww img -o $focused_monitor "$img"
$pywal_refresh
sleep $INTERVAL
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage