about summary refs log tree commit diff stats
path: root/src/event
diff options
context:
space:
mode:
authorJames Booth <boothj5@gmail.com>2015-10-15 01:19:24 +0100
committerJames Booth <boothj5@gmail.com>2015-10-15 01:19:24 +0100
commit904a5a81cfcc19c7029f0a961cfb97f7d1a2fe9f (patch)
tree92a1a43f43f7a5fbbd022fe9b4ccd2fbb1390cb8 /src/event
parentfb60a755e50e8edf8c00ebbf2ba1e707da6ec101 (diff)
downloadprofani-tty-904a5a81cfcc19c7029f0a961cfb97f7d1a2fe9f.tar.gz
Add ability to script commands after connect
Diffstat (limited to 'src/event')
-rw-r--r--src/event/server_events.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/event/server_events.c b/src/event/server_events.c
index 697eb6c9..f46f14ad 100644
--- a/src/event/server_events.c
+++ b/src/event/server_events.c
@@ -43,6 +43,7 @@
 #include "muc.h"
 #include "config/preferences.h"
 #include "config/account.h"
+#include "config/scripts.h"
 #include "roster_list.h"
 #include "window_list.h"
 #include "config/tlscerts.h"
@@ -84,6 +85,11 @@ sv_ev_login_account_success(char *account_name, int secured)
     g_list_free(curr);
 
     log_info("%s logged in successfully", account->jid);
+
+    if (account->startscript) {
+        scripts_exec(account->startscript);
+    }
+
     account_free(account);
 }