aboutsummaryrefslogtreecommitdiffstats
path: root/cgit.c
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2014-12-29 17:05:07 +0100
committerFlorian Pritz <bluewind@xinu.at>2014-12-29 17:52:56 +0100
commit4f5e9b0d6c1090681c489a10179ff1a7c215ac19 (patch)
treeac7bece975e3b7394b2c30a9a404212270d31955 /cgit.c
parent7552266aaccb9445e082fc04215afcb55ad543d8 (diff)
downloadcgit-4f5e9b0d6c1090681c489a10179ff1a7c215ac19.tar.gz
cgit-4f5e9b0d6c1090681c489a10179ff1a7c215ac19.tar.xz
Support Git over HTTP using git-http-backendworking
This saves users from the hassle of setting up git-http-backend when they already run cgit. References: man git-http-backend Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'cgit.c')
-rw-r--r--cgit.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/cgit.c b/cgit.c
index 79019c2..0c4a292 100644
--- a/cgit.c
+++ b/cgit.c
@@ -124,6 +124,8 @@ static void config_cb(const char *name, const char *value)
ctx.cfg.head_include = xstrdup(value);
else if (!strcmp(name, "header"))
ctx.cfg.header = xstrdup(value);
+ else if (!strcmp(name, "http-backend-path"))
+ ctx.cfg.http_backend_path = xstrdup(value);
else if (!strcmp(name, "logo"))
ctx.cfg.logo = xstrdup(value);
else if (!strcmp(name, "index-header"))
@@ -353,6 +355,7 @@ static void prepare_context(void)
ctx.cfg.css = "/cgit.css";
ctx.cfg.logo = "/cgit.png";
ctx.cfg.favicon = "/favicon.ico";
+ ctx.cfg.http_backend_path = NULL;
ctx.cfg.local_time = 0;
ctx.cfg.enable_http_clone = 1;
ctx.cfg.enable_index_owner = 1;