X-Git-Url: http://git.bytex64.net/?a=blobdiff_plain;f=lib%2Fperl%2FBlerg-Database%2FDatabase.xs;h=97b426c7a723733aa8b522219e4c1efaa3c0396b;hb=4ebc59f7d9fbd644f2a6a4c5abda2cdd9dcb8476;hp=536bbe153dc5a4c9f884ea555ce9008d23314c37;hpb=657e96693fb11ec6f451a683e2862e1be239beab;p=blerg.git diff --git a/lib/perl/Blerg-Database/Database.xs b/lib/perl/Blerg-Database/Database.xs index 536bbe1..97b426c 100644 --- a/lib/perl/Blerg-Database/Database.xs +++ b/lib/perl/Blerg-Database/Database.xs @@ -10,6 +10,7 @@ #include "database/tags.h" #include "database/subscription.h" #include "database/util.h" +#include "database/configuration.h" #include "common/auth.h" #include "const-c.inc" @@ -210,3 +211,15 @@ void auth_get_counter(const char *username) } else { XSRETURN_UNDEF; } + +void configuration() + INIT: + HV *confhash; + PPCODE: + confhash = newHV(); + hv_store(confhash, "base_path", 9, newSVpv(blergconf.base_path, 0), 0); + hv_store(confhash, "data_path", 9, newSVpv(blergconf.data_path, 0), 0); + hv_store(confhash, "hash_tags_path", 14, newSVpv(blergconf.hash_tags_path, 0), 0); + hv_store(confhash, "ref_tags_path", 13, newSVpv(blergconf.ref_tags_path, 0), 0); + + XPUSHs(sv_2mortal(newRV_noinc((SV*)confhash)));