|
diff --git a/cgit.c b/cgit.c index 64d95f9..2afc598 100644 --- a/ cgit.c+++ b/ cgit.c |
|
@@ -18,32 +18,34 @@ |
18 | const char *cgit_version = CGIT_VERSION; |
18 | const char *cgit_version = CGIT_VERSION; |
19 | |
19 | |
20 | void config_cb(const char *name, const char *value) |
20 | void config_cb(const char *name, const char *value) |
21 | { |
21 | { |
22 | if (!strcmp(name, "root-title")) |
22 | if (!strcmp(name, "root-title")) |
23 | ctx.cfg.root_title = xstrdup(value); |
23 | ctx.cfg.root_title = xstrdup(value); |
24 | else if (!strcmp(name, "root-desc")) |
24 | else if (!strcmp(name, "root-desc")) |
25 | ctx.cfg.root_desc = xstrdup(value); |
25 | ctx.cfg.root_desc = xstrdup(value); |
26 | else if (!strcmp(name, "root-readme")) |
26 | else if (!strcmp(name, "root-readme")) |
27 | ctx.cfg.root_readme = xstrdup(value); |
27 | ctx.cfg.root_readme = xstrdup(value); |
28 | else if (!strcmp(name, "css")) |
28 | else if (!strcmp(name, "css")) |
29 | ctx.cfg.css = xstrdup(value); |
29 | ctx.cfg.css = xstrdup(value); |
30 | else if (!strcmp(name, "favicon")) |
30 | else if (!strcmp(name, "favicon")) |
31 | ctx.cfg.favicon = xstrdup(value); |
31 | ctx.cfg.favicon = xstrdup(value); |
32 | else if (!strcmp(name, "footer")) |
32 | else if (!strcmp(name, "footer")) |
33 | ctx.cfg.footer = xstrdup(value); |
33 | ctx.cfg.footer = xstrdup(value); |
| |
34 | else if (!strcmp(name, "head-include")) |
| |
35 | ctx.cfg.head_include = xstrdup(value); |
34 | else if (!strcmp(name, "header")) |
36 | else if (!strcmp(name, "header")) |
35 | ctx.cfg.header = xstrdup(value); |
37 | ctx.cfg.header = xstrdup(value); |
36 | else if (!strcmp(name, "logo")) |
38 | else if (!strcmp(name, "logo")) |
37 | ctx.cfg.logo = xstrdup(value); |
39 | ctx.cfg.logo = xstrdup(value); |
38 | else if (!strcmp(name, "index-header")) |
40 | else if (!strcmp(name, "index-header")) |
39 | ctx.cfg.index_header = xstrdup(value); |
41 | ctx.cfg.index_header = xstrdup(value); |
40 | else if (!strcmp(name, "index-info")) |
42 | else if (!strcmp(name, "index-info")) |
41 | ctx.cfg.index_info = xstrdup(value); |
43 | ctx.cfg.index_info = xstrdup(value); |
42 | else if (!strcmp(name, "logo-link")) |
44 | else if (!strcmp(name, "logo-link")) |
43 | ctx.cfg.logo_link = xstrdup(value); |
45 | ctx.cfg.logo_link = xstrdup(value); |
44 | else if (!strcmp(name, "module-link")) |
46 | else if (!strcmp(name, "module-link")) |
45 | ctx.cfg.module_link = xstrdup(value); |
47 | ctx.cfg.module_link = xstrdup(value); |
46 | else if (!strcmp(name, "virtual-root")) { |
48 | else if (!strcmp(name, "virtual-root")) { |
47 | ctx.cfg.virtual_root = trim_end(value, '/'); |
49 | ctx.cfg.virtual_root = trim_end(value, '/'); |
48 | if (!ctx.cfg.virtual_root && (!strcmp(value, "/"))) |
50 | if (!ctx.cfg.virtual_root && (!strcmp(value, "/"))) |
49 | ctx.cfg.virtual_root = ""; |
51 | ctx.cfg.virtual_root = ""; |
|