From 49628b7749abef98a95e832d8929ff137752db79 Mon Sep 17 00:00:00 2001 From: gutmet Date: Fri, 12 Mar 2021 19:59:39 +0100 Subject: [PATCH] autostart --- dwm.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/dwm.c b/dwm.c index f0d50ee..10e707a 100644 --- a/dwm.c +++ b/dwm.c @@ -222,6 +222,7 @@ static void resizemouse(const Arg *arg); static void resizerequest(XEvent *e); static void restack(Monitor *m); static void run(void); +static void runAutostart(void); static void scan(void); static int sendevent(Window w, Atom proto, int m, long d0, long d1, long d2, long d3, long d4); static void sendmon(Client *c, Monitor *m); @@ -1549,6 +1550,13 @@ run(void) handler[ev.type](&ev); /* call handler */ } +void +runAutostart(void) +{ + system("cd ~/.dwm; ./autostart_blocking.sh"); + system("cd ~/.dwm; ./autostart.sh &"); +} + void scan(void) { @@ -2499,6 +2507,7 @@ main(int argc, char *argv[]) die("pledge"); #endif /* __OpenBSD__ */ scan(); + runAutostart(); run(); cleanup(); XCloseDisplay(dpy);