const char *cgit_version = CGIT_VERSION;
+void add_mimetype(const char *name, const char *value)
+{
+ struct string_list_item *item;
+
+ item = string_list_insert(xstrdup(name), &ctx.cfg.mimetypes);
+ item->util = xstrdup(value);
+}
+
+ struct cgit_filter *new_filter(const char *cmd, int extra_args)
+ {
+ struct cgit_filter *f;
+
+ if (!cmd || !cmd[0])
+ return NULL;
+
+ f = xmalloc(sizeof(struct cgit_filter));
+ f->cmd = xstrdup(cmd);
+ f->argv = xmalloc((2 + extra_args) * sizeof(char *));
+ f->argv[0] = f->cmd;
+ f->argv[1] = NULL;
+ return f;
+ }
+
void config_cb(const char *name, const char *value)
{
if (!strcmp(name, "root-title"))
int summary_branches;
int summary_log;
int summary_tags;
+ struct string_list mimetypes;
+ struct cgit_filter *commit_filter;
+ struct cgit_filter *source_filter;
};
struct cgit_page {