mirror of
https://git.sr.ht/~coasteen/dotfiles
synced 2025-11-04 14:47:38 +01:00
8 lines
315 B
Bash
Executable file
8 lines
315 B
Bash
Executable file
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
WALL_DIR="/home/coast/.local/src/wall"
|
|
SUBDIR=$(find "$WALL_DIR" -mindepth 1 -maxdepth 1 -type d | shuf -n1)
|
|
FILE=$(find "$SUBDIR" -type f \( -iname '*.jpg' -o -iname '*.png' -o -iname '*.jpeg' \) | shuf -n1)
|
|
if [[ -n "$FILE" ]]; then
|
|
swaymsg output '*' bg "$FILE" fill
|
|
fi
|