From f39d735e2ba625a31a7dbf6fb8bdd62501379ad1 Mon Sep 17 00:00:00 2001 From: zachir Date: Wed, 5 Oct 2022 22:00:32 -0500 Subject: Initial Commit --- autostart.sh | 50 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 50 insertions(+) create mode 100755 autostart.sh (limited to 'autostart.sh') diff --git a/autostart.sh b/autostart.sh new file mode 100755 index 0000000..bb5e986 --- /dev/null +++ b/autostart.sh @@ -0,0 +1,50 @@ +#!/bin/sh +runifnot () { + if type $1 >/dev/null; then + echo $1 + if [ -z "$(pgrep -f $1)" ]; then + $@ & + fi + fi +} + +runifnot `crcparse snd` +if type mpd >/dev/null; then + runifnot mpd +elif type musicpd >/dev/null; then + runifnot musicpd +fi +runifnot mpd-mpris -network unix +runifnot mpd-notification +runifnot transmission-daemon +#runifnot dbus-daemon --session --address=unix:path=$XDG_RUNTIME_DIR/bus +runifnot openrazer-daemon +runifnot lxqt-policykit-agent +razer-cli -e static & +#runifnot nextcloud +if [ -z "$WAYLAND_DISPLAY" ]; then + runifnot xss-lock -n notify-send slockd + #if pgrep -x swhkd; then + # doas killall swhkd && pkexec swhkd + #fi + #pkexec swhkd & + #runifnot swhks + runifnot sxhkd + runifnot dunst + runifnot caffeine-ng + if [ "$(crcparse WM)" = "$(which xmonad)" ]; then + runifnot stalonetray + fi + xwallpaper --zoom ~/background.jpg + setxkbmap -option "caps:escape" +else + toggle swaybg -i ~/background.jpg + gsettings set org.gnome.desktop.interface gtk-theme Sweet-Dark-v40 + gsettings set org.gnome.desktop.interface icon-theme Paper-Mono-Dark + runifnot swayidle -w + hotkeys.sh + runifnot mako + if [ "$(crcparse WC)" != "$(which qtile)" ]; then + runifnot waybar + fi +fi -- cgit v1.2.3