]> gitweb.ps.run Git - ps-cgit/blobdiff - cgit.h
Add generic filter/plugin infrastructure
[ps-cgit] / cgit.h
diff --git a/cgit.h b/cgit.h
index 8b0defa988d062a24fa40dbcd7a39d2b68de61cb..d0fff1f7f8cd5a0af073afce2d8ea23301811154 100644 (file)
--- a/cgit.h
+++ b/cgit.h
@@ -129,6 +129,15 @@ struct cgit_query {
        int showmsg;
 };
 
+struct cgit_filter {
+       char *cmd;
+       char **argv;
+       int old_stdout;
+       int pipe_fh[2];
+       int pid;
+       int exitstatus;
+};
+
 struct cgit_config {
        char *agefile;
        char *cache_root;
@@ -136,6 +145,8 @@ struct cgit_config {
        char *css;
        char *favicon;
        char *footer;
+       char *head_include;
+       char *header;
        char *index_header;
        char *index_info;
        char *logo;
@@ -154,6 +165,7 @@ struct cgit_config {
        int cache_repo_ttl;
        int cache_root_ttl;
        int cache_static_ttl;
+       int embedded;
        int enable_index_links;
        int enable_log_filecount;
        int enable_log_linecount;
@@ -165,6 +177,7 @@ struct cgit_config {
        int max_repodesc_len;
        int max_stats;
        int nocache;
+       int noheader;
        int renamelimit;
        int snapshots;
        int summary_branches;
@@ -179,7 +192,10 @@ struct cgit_page {
        char *mimetype;
        char *charset;
        char *filename;
+       char *etag;
        char *title;
+       int status;
+       char *statusmsg;
 };
 
 struct cgit_context {
@@ -241,5 +257,8 @@ extern const char *cgit_repobasename(const char *reponame);
 
 extern int cgit_parse_snapshots_mask(const char *str);
 
+extern int cgit_open_filter(struct cgit_filter *filter);
+extern int cgit_close_filter(struct cgit_filter *filter);
+
 
 #endif /* CGIT_H */