mirror of
				https://github.com/bytequill/dotfiles.git
				synced 2025-11-04 12:19:19 +01:00 
			
		
		
		
	Fix wallpaper.sh
This commit is contained in:
		
							parent
							
								
									0d7efc942f
								
							
						
					
					
						commit
						8e78ec129f
					
				@ -28,7 +28,7 @@ if [[ ! -d "$DIR" ]]; then
 | 
				
			|||||||
    exit 2
 | 
					    exit 2
 | 
				
			||||||
fi
 | 
					fi
 | 
				
			||||||
 | 
					
 | 
				
			||||||
FILE=$(find "$DIR" -type f | shuf -n1)
 | 
					FILE=$(find "$DIR" -type f,l | shuf -n1)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
if [[ -z "$FILE" ]]; then
 | 
					if [[ -z "$FILE" ]]; then
 | 
				
			||||||
    echo "Error: No files found in '$DIR'." >&2
 | 
					    echo "Error: No files found in '$DIR'." >&2
 | 
				
			||||||
@ -42,7 +42,7 @@ hyprctl hyprpaper preload "$FILE"
 | 
				
			|||||||
echo "Info: Selecting wallpaper"
 | 
					echo "Info: Selecting wallpaper"
 | 
				
			||||||
for monitor in $(hyprctl monitors | grep 'Monitor' | awk '{ print $2 }'); do
 | 
					for monitor in $(hyprctl monitors | grep 'Monitor' | awk '{ print $2 }'); do
 | 
				
			||||||
	echo  "	Info: Selecting wallpaper for: '$monitor'"
 | 
						echo  "	Info: Selecting wallpaper for: '$monitor'"
 | 
				
			||||||
	hyprctl hyprpaper wallpaper "eDP-1,$MODE$FILE"
 | 
						hyprctl hyprpaper wallpaper "$monitor,$MODE$FILE"
 | 
				
			||||||
done
 | 
					done
 | 
				
			||||||
echo "Info: Unloading unused wallpapers"
 | 
					echo "Info: Unloading unused wallpapers"
 | 
				
			||||||
hyprctl hyprpaper unload all
 | 
					hyprctl hyprpaper unload all
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user