mirror of
https://gitlab.com/Zaney/zaneyos.git
synced 2025-06-24 22:12:04 +02:00
Fix timeout, and source the user set wallpaperDir
This commit is contained in:
parent
96c8731c47
commit
37a5fd5008
@ -1,13 +1,13 @@
|
||||
{ pkgs, username, wallpaperDir, wallpaperGit, ... }:
|
||||
|
||||
pkgs.writeShellScriptBin "wallsetter" ''
|
||||
TIMEOUT=5
|
||||
TIMEOUT=720
|
||||
TRANSITION1="--transition-type wave --transition-angle 120 --transition-step 30"
|
||||
TRANSITION2="--transition-type wipe --transition-angle 30 --transition-step 30"
|
||||
TRANSITION3="--transition-type center --transition-step 30"
|
||||
TRANSITION4="--transition-type outer --transition-pos 0.3,0.8 --transition-step 30"
|
||||
TRANSITION5="--transition-type wipe --transition-angle 270 --transition-step 30"
|
||||
WALLPAPER=$(find $HOME/Pictures/Wallpapers/ -name '*' | awk '!/.git/' | tail -n +2 | sed 's/ /\\ /g' | shuf -n 1)
|
||||
WALLPAPER=$(find ${wallpaperDir} -name '*' | awk '!/.git/' | tail -n +2 | sed 's/ /\\ /g' | shuf -n 1)
|
||||
PREVIOUS=$WALLPAPER
|
||||
if [ -d ${wallpaperDir} ]; then
|
||||
cd ${wallpaperDir}
|
||||
@ -20,7 +20,7 @@ pkgs.writeShellScriptBin "wallsetter" ''
|
||||
do
|
||||
if [ "$WALLPAPER" == "$PREVIOUS" ]
|
||||
then
|
||||
WALLPAPER=$(find $HOME/Pictures/Wallpapers/ -name '*' | awk '!/.git/' | tail -n +2 | sed 's/ /\\ /g' | shuf -n 1)
|
||||
WALLPAPER=$(find ${wallpaperDir} -name '*' | awk '!/.git/' | tail -n +2 | sed 's/ /\\ /g' | shuf -n 1)
|
||||
else
|
||||
PREVIOUS=$WALLPAPER
|
||||
NUM=$(shuf -i 1-5 -n 1)
|
||||
|
Loading…
x
Reference in New Issue
Block a user