|
diff --git a/cgit.c b/cgit.c index bd37788..ff678fb 100644 --- a/ cgit.c+++ b/ cgit.c |
|
@@ -181,8 +181,10 @@ void config_cb(const char *name, const char *value) |
181 | else if (!strcmp(name, "summary-branches")) |
181 | else if (!strcmp(name, "summary-branches")) |
182 | ctx.cfg.summary_branches = atoi(value); |
182 | ctx.cfg.summary_branches = atoi(value); |
183 | else if (!strcmp(name, "summary-tags")) |
183 | else if (!strcmp(name, "summary-tags")) |
184 | ctx.cfg.summary_tags = atoi(value); |
184 | ctx.cfg.summary_tags = atoi(value); |
| |
185 | else if (!strcmp(name, "side-by-side-diffs")) |
| |
186 | ctx.cfg.ssdiff = atoi(value); |
185 | else if (!strcmp(name, "agefile")) |
187 | else if (!strcmp(name, "agefile")) |
186 | ctx.cfg.agefile = xstrdup(value); |
188 | ctx.cfg.agefile = xstrdup(value); |
187 | else if (!strcmp(name, "renamelimit")) |
189 | else if (!strcmp(name, "renamelimit")) |
188 | ctx.cfg.renamelimit = atoi(value); |
190 | ctx.cfg.renamelimit = atoi(value); |
@@ -237,8 +239,10 @@ static void querystring_cb(const char *name, const char *value) |
237 | } else if (!strcmp(name, "showmsg")) { |
239 | } else if (!strcmp(name, "showmsg")) { |
238 | ctx.qry.showmsg = atoi(value); |
240 | ctx.qry.showmsg = atoi(value); |
239 | } else if (!strcmp(name, "period")) { |
241 | } else if (!strcmp(name, "period")) { |
240 | ctx.qry.period = xstrdup(value); |
242 | ctx.qry.period = xstrdup(value); |
| |
243 | } else if (!strcmp(name, "ss")) { |
| |
244 | ctx.qry.ssdiff = atoi(value); |
241 | } |
245 | } |
242 | } |
246 | } |
243 | |
247 | |
244 | char *xstrdupn(const char *str) |
248 | char *xstrdupn(const char *str) |
@@ -278,8 +282,9 @@ static void prepare_context(struct cgit_context *ctx) |
278 | ctx->cfg.section = ""; |
282 | ctx->cfg.section = ""; |
279 | ctx->cfg.summary_branches = 10; |
283 | ctx->cfg.summary_branches = 10; |
280 | ctx->cfg.summary_log = 10; |
284 | ctx->cfg.summary_log = 10; |
281 | ctx->cfg.summary_tags = 10; |
285 | ctx->cfg.summary_tags = 10; |
| |
286 | ctx->cfg.ssdiff = 0; |
282 | ctx->env.cgit_config = xstrdupn(getenv("CGIT_CONFIG")); |
287 | ctx->env.cgit_config = xstrdupn(getenv("CGIT_CONFIG")); |
283 | ctx->env.http_host = xstrdupn(getenv("HTTP_HOST")); |
288 | ctx->env.http_host = xstrdupn(getenv("HTTP_HOST")); |
284 | ctx->env.https = xstrdupn(getenv("HTTPS")); |
289 | ctx->env.https = xstrdupn(getenv("HTTPS")); |
285 | ctx->env.no_http = xstrdupn(getenv("NO_HTTP")); |
290 | ctx->env.no_http = xstrdupn(getenv("NO_HTTP")); |
|