feat: support new monitor
This commit is contained in:
parent
b234bdbd06
commit
271cbb359b
6 changed files with 139 additions and 58 deletions
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
WALLPAPERS_PATH="$HOME/.config/wallpapers"
|
||||
WALLPAPERS=$(find "$WALLPAPERS_PATH" -type f,l)
|
||||
DEBUG=0
|
||||
|
||||
function help() {
|
||||
echo "Usage:"
|
||||
|
|
@ -22,7 +23,11 @@ function setWallpaperX {
|
|||
}
|
||||
|
||||
function setWallpaperWayland {
|
||||
swaybg --mode fill -i "$1" 2>/dev/null &
|
||||
if [[ $DEBUG -eq 1 ]]; then
|
||||
swaybg --mode fill -i "$1" &
|
||||
else
|
||||
swaybg --mode fill -i "$1" 2>/dev/null &
|
||||
fi
|
||||
}
|
||||
|
||||
function setWallpaper() {
|
||||
|
|
@ -53,6 +58,10 @@ while [[ $# -gt 0 ]]; do
|
|||
shift # past argument
|
||||
shift # past value
|
||||
;;
|
||||
-v | --verbose)
|
||||
DEBUG=1
|
||||
shift # past argument
|
||||
;;
|
||||
*)
|
||||
POSITIONAL+=("$1") # save it in an array for later
|
||||
shift # past argument
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue