diff options
| author | JaKooLit <jimmielovejay@gmail.com> | 2023-11-06 10:34:28 +0900 |
|---|---|---|
| committer | JaKooLit <jimmielovejay@gmail.com> | 2023-11-06 10:34:28 +0900 |
| commit | 8f2b0a6d7437e73f777cfad809fb950c0f2c9491 (patch) | |
| tree | f5db42a96637383f3a8116244387db290f44d6c5 /config/hypr | |
| parent | efb6137d6a2e5f91b526341579a216b880286063 (diff) | |
initial boot script to for pywal & wallpaper set
Diffstat (limited to 'config/hypr')
| -rw-r--r-- | config/hypr/configs/Execs.conf | 4 | ||||
| -rw-r--r-- | config/hypr/initial-boot.sh | 27 |
2 files changed, 30 insertions, 1 deletions
diff --git a/config/hypr/configs/Execs.conf b/config/hypr/configs/Execs.conf index 9691e5cf..92771f61 100644 --- a/config/hypr/configs/Execs.conf +++ b/config/hypr/configs/Execs.conf @@ -3,10 +3,12 @@ $scriptsDir = $HOME/.config/hypr/scripts $themes = $HOME/.config/hypr/themes $lock = $scriptsDir/LockScreen.sh +# Initial boot script to start Pywal and Set wallpaper. This line and corresponding script can be safely deleted once logged in +exec-once = $HOME/.config/hypr/initial-boot.sh + # wallpaper stuff exec-once = swww query || swww init #exec-once = swww query || swww init && swww img $HOME/Pictures/wallpapers/mecha-nostalgia.png #using swww utility -#exec-once = swaybg -m fill -i $HOME/Pictures/wallpapers/mecha-nostalgia.png #using swaybg # Startup exec-once = dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP diff --git a/config/hypr/initial-boot.sh b/config/hypr/initial-boot.sh new file mode 100644 index 00000000..a024ce63 --- /dev/null +++ b/config/hypr/initial-boot.sh @@ -0,0 +1,27 @@ +#!/bin/bash + +# THIS SCRIPT CAN BE DELETED ONCE BOOTED!! + +# A bash script designed to ran it only once dotfiles installed +# Check if a marker file exists. +if [ ! -f ~/.hyprland_startup_done ]; then + + # Check if the ~/.cache/wal directory exists + if [ ! -d ~/.cache/wal ]; then + printf " Initializing pywal........\n\n" + # Check if the ~/Pictures/wallpapers directory exists + if [ -d ~/Pictures/wallpapers ]; then + # Run wal with random wallpapers from ~/Pictures/wallpapers + wal -i ~/Pictures/wallpapers/* + echo "Pywal initialized" + fi + fi + + # Initializing the initial wallpaper and wal + exec ~/.config/hypr/scripts/Wallpaper.sh + + # Create a marker file to indicate that the script has been executed. + touch ~/.hyprland_startup_done +fi + + |
