]> gitweb.ps.run Git - ps-cgit/blobdiff - shared.c
Add config param 'index-info'
[ps-cgit] / shared.c
index 7eb2b0e26d8db080159f6ce3ee9fe9251853c6ce..50fe8e1343437380b035aa98cc120c2b8b9bc2da 100644 (file)
--- a/shared.c
+++ b/shared.c
@@ -18,6 +18,7 @@ char *cgit_root_title   = "Git repository browser";
 char *cgit_css          = "/cgit.css";
 char *cgit_logo         = "/git-logo.png";
 char *cgit_index_header = NULL;
 char *cgit_css          = "/cgit.css";
 char *cgit_logo         = "/git-logo.png";
 char *cgit_index_header = NULL;
+char *cgit_index_info   = NULL;
 char *cgit_logo_link    = "http://www.kernel.org/pub/software/scm/git/docs/";
 char *cgit_module_link  = "./?repo=%s&page=commit&id=%s";
 char *cgit_agefile      = "info/web/last-modified";
 char *cgit_logo_link    = "http://www.kernel.org/pub/software/scm/git/docs/";
 char *cgit_module_link  = "./?repo=%s&page=commit&id=%s";
 char *cgit_agefile      = "info/web/last-modified";
@@ -54,6 +55,7 @@ char *cgit_query_repo   = NULL;
 char *cgit_query_page   = NULL;
 char *cgit_query_head   = NULL;
 char *cgit_query_search = NULL;
 char *cgit_query_page   = NULL;
 char *cgit_query_head   = NULL;
 char *cgit_query_search = NULL;
+char *cgit_query_grep   = NULL;
 char *cgit_query_sha1   = NULL;
 char *cgit_query_sha2   = NULL;
 char *cgit_query_path   = NULL;
 char *cgit_query_sha1   = NULL;
 char *cgit_query_sha2   = NULL;
 char *cgit_query_path   = NULL;
@@ -149,6 +151,8 @@ void cgit_global_config_cb(const char *name, const char *value)
                cgit_logo = xstrdup(value);
        else if (!strcmp(name, "index-header"))
                cgit_index_header = xstrdup(value);
                cgit_logo = xstrdup(value);
        else if (!strcmp(name, "index-header"))
                cgit_index_header = xstrdup(value);
+       else if (!strcmp(name, "index-info"))
+               cgit_index_info = xstrdup(value);
        else if (!strcmp(name, "logo-link"))
                cgit_logo_link = xstrdup(value);
        else if (!strcmp(name, "module-link"))
        else if (!strcmp(name, "logo-link"))
                cgit_logo_link = xstrdup(value);
        else if (!strcmp(name, "module-link"))
@@ -232,6 +236,8 @@ void cgit_querystring_cb(const char *name, const char *value)
                cgit_cmd = cgit_get_cmd_index(value);
        } else if (!strcmp(name, "url")) {
                cgit_parse_url(value);
                cgit_cmd = cgit_get_cmd_index(value);
        } else if (!strcmp(name, "url")) {
                cgit_parse_url(value);
+       } else if (!strcmp(name, "qt")) {
+               cgit_query_grep = xstrdup(value);
        } else if (!strcmp(name, "q")) {
                cgit_query_search = xstrdup(value);
        } else if (!strcmp(name, "h")) {
        } else if (!strcmp(name, "q")) {
                cgit_query_search = xstrdup(value);
        } else if (!strcmp(name, "h")) {