1
0
Fork 0
This commit is contained in:
Luca Bilke 2024-02-03 18:24:46 +01:00
parent a87cfa097e
commit bbb1c368a0
2 changed files with 13 additions and 15 deletions

View file

@ -1,4 +1,5 @@
#!/bin/sh #!/bin/sh
# WARN: this will clobber logfiles
LOGFILE="${LOGFILE:-${HOME}/.local/log/${1}.log}" LOGFILE="${LOGFILE:-${HOME}/.local/log/${1}.log}"
BOLD="$(tput bold)" BOLD="$(tput bold)"
@ -8,13 +9,13 @@ NC="$(tput sgr0)"
infolog() { infolog() {
while IFS= read -r line; do while IFS= read -r line; do
echo "[$(date +%X)][${BOLD}${GREEN}INF${NC}][$1] $line" >>"${LOGFILE}" echo "[$(date +%X)][${BOLD}${GREEN}INF${NC}][$1] $line" >"${LOGFILE}"
done done
} }
errorlog() { errorlog() {
while IFS= read -r line; do while IFS= read -r line; do
echo "[$(date +%X)][${BOLD}${RED}ERR${NC}][$1] $line" >>"${LOGFILE}" echo "[$(date +%X)][${BOLD}${RED}ERR${NC}][$1] $line" >"${LOGFILE}"
done done
} }

View file

@ -5,16 +5,6 @@ start() {
pidof -sx "$1" || "$@" & pidof -sx "$1" || "$@" &
} }
remaps -qd
xwallpaper --zoom "$XDG_DATA_HOME/bg"
unclutter -noevents &
start gpgconf --launch gpg-agent
start dwmblocks
start picom
start pipewire
start dunst
# Set up xsecurelock # Set up xsecurelock
xset s 300 xset s 300
env \ env \
@ -35,8 +25,15 @@ env \
XSECURELOCK_SHOW_HOSTNAME=1 \ XSECURELOCK_SHOW_HOSTNAME=1 \
xss-lock -n /usr/libexec/xsecurelock/dimmer -l -- sh -c "xsecurelock -- playerctl pause || kill -9 -1" & xss-lock -n /usr/libexec/xsecurelock/dimmer -l -- sh -c "xsecurelock -- playerctl pause || kill -9 -1" &
# Run host autostart
[ -r "$XDG_CONFIG_HOME/dwm/host.sh" ] && "$XDG_CONFIG_HOME/dwm/host.sh" & [ -r "$XDG_CONFIG_HOME/dwm/host.sh" ] && "$XDG_CONFIG_HOME/dwm/host.sh" &
# Check for updates xwallpaper --zoom "$XDG_DATA_HOME/bg"
checkup & remaps -qd
start unclutter -noevents &
start gpgconf --launch gpg-agent
start dwmblocks
start picom
start pipewire
start dunst
start checkup