diff --git a/.gitignore b/.gitignore index a6be96e..57a9c12 100644 --- a/.gitignore +++ b/.gitignore @@ -6,3 +6,5 @@ msgs/* node* doors/* last10.dat +ansis/* +config/* diff --git a/ansis/bulletin0.ans b/ansis_default/bulletin0.ans similarity index 100% rename from ansis/bulletin0.ans rename to ansis_default/bulletin0.ans diff --git a/ansis/doors.ans b/ansis_default/doors.ans similarity index 100% rename from ansis/doors.ans rename to ansis_default/doors.ans diff --git a/ansis/goodbye.ans b/ansis_default/goodbye.ans similarity index 100% rename from ansis/goodbye.ans rename to ansis_default/goodbye.ans diff --git a/ansis/issue.ans b/ansis_default/issue.ans similarity index 100% rename from ansis/issue.ans rename to ansis_default/issue.ans diff --git a/ansis/mailmenu.ans b/ansis_default/mailmenu.ans similarity index 100% rename from ansis/mailmenu.ans rename to ansis_default/mailmenu.ans diff --git a/ansis/mainmenu.ans b/ansis_default/mainmenu.ans similarity index 100% rename from ansis/mainmenu.ans rename to ansis_default/mainmenu.ans diff --git a/ansis/newuser.ans b/ansis_default/newuser.ans similarity index 100% rename from ansis/newuser.ans rename to ansis_default/newuser.ans diff --git a/bbs.c b/bbs.c index 18e5190..5ed11a8 100644 --- a/bbs.c +++ b/bbs.c @@ -8,6 +8,7 @@ #include #include #include +#include #include "inih/ini.h" #include "bbs.h" @@ -440,7 +441,7 @@ void runbbs(int socket, char *config_path) { } } - if (ini_parse("doors.ini", door_config_handler, &conf) <0) { + if (ini_parse("config/doors.ini", door_config_handler, &conf) <0) { printf("Unable to load configuration ini (doors.ini)!\n"); exit(-1); } diff --git a/bbs.ini b/config_default/bbs.ini similarity index 71% rename from bbs.ini rename to config_default/bbs.ini index 1bbccd0..00f8401 100644 --- a/bbs.ini +++ b/config_default/bbs.ini @@ -1,6 +1,6 @@ [main] -BBS Name = Enigma BBS -Sysop Name = Andrew Pamment +BBS Name = Magicka BBS +Sysop Name = sysop nodes = 4 New User Level = 10 @@ -10,4 +10,4 @@ BBS Path = /home/andrew/MagickaBBS Email Path = /home/andrew/MagickaBBS/msgs/email [mail conferences] -Local Mail = localmail.ini +Local Mail = config/localmail.ini diff --git a/doors.ini b/config_default/doors.ini similarity index 100% rename from doors.ini rename to config_default/doors.ini diff --git a/localmail.ini b/config_default/localmail.ini similarity index 100% rename from localmail.ini rename to config_default/localmail.ini diff --git a/s10.ini b/config_default/s10.ini similarity index 100% rename from s10.ini rename to config_default/s10.ini diff --git a/main.c b/main.c index d3fd263..4abcc6c 100644 --- a/main.c +++ b/main.c @@ -14,7 +14,7 @@ int main(int argc, char **argv) { int port; if (argc < 3) { - printf("Usage ./magicka bbs.ini port\n"); + printf("Usage ./magicka config/bbs.ini port\n"); exit(1); } diff --git a/users.c b/users.c index 82b873a..918a84c 100644 --- a/users.c +++ b/users.c @@ -432,7 +432,7 @@ struct user_record *new_user(int socket) { user->sec_info = (struct sec_level_t *)malloc(sizeof(struct sec_level_t)); - sprintf(buffer, "%s/s%d.ini", conf.bbs_path, user->sec_level); + sprintf(buffer, "%s/config/s%d.ini", conf.bbs_path, user->sec_level); if (ini_parse(buffer, secLevel, user->sec_info) <0) { printf("Unable to load sec Level ini (%s)!\n", buffer);