mirror of
https://github.com/danielepintore/dotfiles.git
synced 2026-06-15 20:25:13 +02:00
Update wallpapers. now use hyprpaper and we have a custom script to
select a wallpaper. Fixed wrong rofi drun exec command now we use uwsm app -- to launch the applications
This commit is contained in:
@@ -1,18 +1,26 @@
|
||||
#!/bin/sh
|
||||
mkdir -p ~/.config/hypr/hyprlock/
|
||||
wallpaper=$(find ~/.config/hypr/wallpapers/ -type f | shuf -n1)
|
||||
swaybg -i $wallpaper &
|
||||
# Update hyprlock background
|
||||
cp $wallpaper ~/.config/hypr/hyprlock/background.jpg
|
||||
OLD_PID=$!
|
||||
while true; do
|
||||
wallpaper=$(find ~/.config/hypr/wallpapers/ -type f | shuf -n1)
|
||||
sleep 600
|
||||
swaybg -i $wallpaper &
|
||||
# Update hyprlock background
|
||||
cp $wallpaper ~/.config/hypr/hyprlock/background.jpg
|
||||
NEXT_PID=$!
|
||||
sleep 5
|
||||
kill $OLD_PID
|
||||
OLD_PID=$NEXT_PID
|
||||
done
|
||||
#!/usr/bin/env bash
|
||||
|
||||
# You can run this script with the random parameter to select a random wallpaper
|
||||
# from the active wallpaper directory. Otherwise a prompt will appear asking
|
||||
# for a wallpaper
|
||||
|
||||
WALLPAPER_DIR="$HOME/.config/hypr/wallpapers/"
|
||||
CURRENT_WALL=$(hyprctl hyprpaper listloaded)
|
||||
|
||||
if [[ $1 == "random" ]];then
|
||||
# Get a random wallpaper that is not the current one
|
||||
WALLPAPER=$(find "$WALLPAPER_DIR" -type f ! -name "$(basename "$CURRENT_WALL")" | shuf -n 1)
|
||||
else
|
||||
CHOICE=$(find $WALLPAPER_DIR -maxdepth 1 -type f -printf "%f\n" | sort | rofi -dmenu -p "Wallpaper: ")
|
||||
WALLPAPER="$WALLPAPER_DIR$CHOICE"
|
||||
# if we quit rofi then WALLPAPER == WALLPAPER_DIR then we need to quit without
|
||||
# changing the wallpaper
|
||||
if [[ $WALLPAPER_DIR == $WALLPAPER ]];then
|
||||
exit 0
|
||||
fi
|
||||
fi
|
||||
|
||||
# Apply the selected wallpaper
|
||||
hyprctl hyprpaper reload ,"$WALLPAPER"
|
||||
# set background for hyprlock
|
||||
ln -sf $WALLPAPER $HOME/.config/hypr/hyprlock/background.jpg
|
||||
|
||||
@@ -23,9 +23,8 @@ monitor=eDP-1,1920x1200,auto,1.25
|
||||
#exec-once = uwsm app -- hyprlock
|
||||
exec-once = uwsm app -- waybar
|
||||
exec-once= uwsm app -- /usr/lib/polkit-kde-authentication-agent-1
|
||||
# Select random wallpaper from wallpaper folder
|
||||
exec-once = uwsm app -- swaybg -i ~/.config/hypr/wallpapers/wallpaper.jpg
|
||||
#exec-once = ~/.config/hypr/change_wallpaper.sh
|
||||
# select a random wallpaper
|
||||
exec-once = uwsm app -- uwsm app -- sh -c '$(xdg-user-dir HOME)/.config/hypr/change_wallpaper.sh random'
|
||||
exec-once = uwsm app -- dunst
|
||||
exec-once = uwsm app -- batsignal -b -e -w 30 -c 20 -d 10 -f 100
|
||||
exec-once = uwsm app -- nm-applet
|
||||
@@ -151,10 +150,11 @@ bind = $mainMod, C, killactive,
|
||||
bind = $mainMod, M, exec, uwsm stop
|
||||
bind = $mainMod, E, exec, uwsm app -- nemo
|
||||
bind = $mainMod, W, exec, uwsm app -- firefox
|
||||
bind = $mainMod SHIFT, W, exec, uwsm app -- sh -c '$(xdg-user-dir HOME)/.config/hypr/change_wallpaper.sh'
|
||||
bind = $mainMod, T, togglefloating,
|
||||
bind = $mainMod, S, exec, uwsm app -- sh -c 'IMG=$(xdg-user-dir PICTURES)/Screenshots/$(date +'%s_grim.png') && grim $IMG && wl-copy < $IMG' # screenshot
|
||||
bind = $mainMod SHIFT, S, exec, uwsm app -- sh -c 'IMG=$(xdg-user-dir PICTURES)/Screenshots/$(date +'%s_grim.png') && grim -g "$(slurp)" $IMG && wl-copy < $IMG' # screenshot only a part of the screen
|
||||
bind = $mainMod, R, exec, uwsm app -- rofi -run-command='nemo .; {cmd}' -show drun
|
||||
bind = $mainMod, R, exec, uwsm app -- rofi -run-command='uwsm app -- {cmd}' -show drun
|
||||
bind = $mainMod, P, pseudo, # dwindle
|
||||
bind = $mainMod, J, togglesplit, # dwindle
|
||||
bind = $mainMod, F, fullscreen,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
background {
|
||||
monitor =
|
||||
path = ~/.config/hypr/wallpapers/wallpaper.jpg
|
||||
path = ~/.config/hypr/hyprlock/background.jpg
|
||||
color = rgba(25, 20, 20, 1.0)
|
||||
|
||||
# all these options are taken from hyprland, see https://wiki.hyprland.org/Configuring/Variables/#blur for explanations
|
||||
|
||||
1
.config/hypr/hyprlock/background.jpg
Symbolic link
1
.config/hypr/hyprlock/background.jpg
Symbolic link
@@ -0,0 +1 @@
|
||||
/home/daniele/.config/hypr/wallpapers/chainsaw-man-war-devil-bw.jpg
|
||||
0
.config/hypr/hyprpaper.conf
Normal file
0
.config/hypr/hyprpaper.conf
Normal file
Reference in New Issue
Block a user