X-Git-Url: https://git.ozlabs.org/?p=ccan;a=blobdiff_plain;f=tools%2F_infotojson%2Finfotojson.h;h=7b979240eaac17b751a6a886a86a2458ac26fb93;hp=c3c9658c53fd2831e687a600e694d750aea20af2;hb=cc1e3419b6c5e4abf1b99b0094bc3e134356525e;hpb=9012570621c210f0fb41d60446e39d7ef5788f54 diff --git a/tools/_infotojson/infotojson.h b/tools/_infotojson/infotojson.h index c3c9658c..7b979240 100644 --- a/tools/_infotojson/infotojson.h +++ b/tools/_infotojson/infotojson.h @@ -15,23 +15,25 @@ #include "ccan/talloc/talloc.h" #include "ccan/string/string.h" #include "utils.h" +#include "tools/tools.h" struct json { char *module; char *title; char *author; + char **depends; char **desc; }; /* Function for storing json structure to file given struct json*/ -int storejsontofile(struct json *jsonobj, char *jsonfile); +static int storejsontofile(const struct json *jsonobj, const char *jsonfile); /*Function to store in database*/ -int storejsontodb(struct json *jsonobj, char *db); +static int storejsontodb(const struct json *jsonobj, const char *db); /*create json structure*/ -struct json * createjson(char **infofile, char *author); +static struct json *createjson(char **infofile, const char *author, const char *directory); /*Extract info from file*/ -char ** extractinfo(char **file); +static char **extractinfo(char **file);