author | Florian Pritz <bluewind@xssn.at> | 2009-08-09 20:42:45 (UTC) |
---|---|---|
committer | Lars Hjemli <hjemli@gmail.com> | 2009-08-21 12:17:49 (UTC) |
commit | d67cc7f9d556650438e421cdcda37bc52710bffd (patch) (unidiff) | |
tree | df131c58de7c712550f124f8fb15aef303ff6054 /cgit.c | |
parent | 03389d6e67bfda5cb3ff1504db815f09715ec6f4 (diff) | |
download | cgit-d67cc7f9d556650438e421cdcda37bc52710bffd.zip cgit-d67cc7f9d556650438e421cdcda37bc52710bffd.tar.gz cgit-d67cc7f9d556650438e421cdcda37bc52710bffd.tar.bz2 |
Add 'linenumbers' config option
Signed-off-by: Florian Pritz <bluewind@xssn.at>
Signed-off-by: Lars Hjemli <hjemli@gmail.com>
-rw-r--r-- | cgit.c | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -53,32 +53,34 @@ void config_cb(const char *name, const char *value) | |||
53 | else if (!strcmp(name, "favicon")) | 53 | else if (!strcmp(name, "favicon")) |
54 | ctx.cfg.favicon = xstrdup(value); | 54 | ctx.cfg.favicon = xstrdup(value); |
55 | else if (!strcmp(name, "footer")) | 55 | else if (!strcmp(name, "footer")) |
56 | ctx.cfg.footer = xstrdup(value); | 56 | ctx.cfg.footer = xstrdup(value); |
57 | else if (!strcmp(name, "head-include")) | 57 | else if (!strcmp(name, "head-include")) |
58 | ctx.cfg.head_include = xstrdup(value); | 58 | ctx.cfg.head_include = xstrdup(value); |
59 | else if (!strcmp(name, "header")) | 59 | else if (!strcmp(name, "header")) |
60 | ctx.cfg.header = xstrdup(value); | 60 | ctx.cfg.header = xstrdup(value); |
61 | else if (!strcmp(name, "logo")) | 61 | else if (!strcmp(name, "logo")) |
62 | ctx.cfg.logo = xstrdup(value); | 62 | ctx.cfg.logo = xstrdup(value); |
63 | else if (!strcmp(name, "index-header")) | 63 | else if (!strcmp(name, "index-header")) |
64 | ctx.cfg.index_header = xstrdup(value); | 64 | ctx.cfg.index_header = xstrdup(value); |
65 | else if (!strcmp(name, "index-info")) | 65 | else if (!strcmp(name, "index-info")) |
66 | ctx.cfg.index_info = xstrdup(value); | 66 | ctx.cfg.index_info = xstrdup(value); |
67 | else if (!strcmp(name, "logo-link")) | 67 | else if (!strcmp(name, "logo-link")) |
68 | ctx.cfg.logo_link = xstrdup(value); | 68 | ctx.cfg.logo_link = xstrdup(value); |
69 | else if (!strcmp(name, "linenumbers")) | ||
70 | ctx.cfg.linenumbers = atoi(value); | ||
69 | else if (!strcmp(name, "module-link")) | 71 | else if (!strcmp(name, "module-link")) |
70 | ctx.cfg.module_link = xstrdup(value); | 72 | ctx.cfg.module_link = xstrdup(value); |
71 | else if (!strcmp(name, "virtual-root")) { | 73 | else if (!strcmp(name, "virtual-root")) { |
72 | ctx.cfg.virtual_root = trim_end(value, '/'); | 74 | ctx.cfg.virtual_root = trim_end(value, '/'); |
73 | if (!ctx.cfg.virtual_root && (!strcmp(value, "/"))) | 75 | if (!ctx.cfg.virtual_root && (!strcmp(value, "/"))) |
74 | ctx.cfg.virtual_root = ""; | 76 | ctx.cfg.virtual_root = ""; |
75 | } else if (!strcmp(name, "nocache")) | 77 | } else if (!strcmp(name, "nocache")) |
76 | ctx.cfg.nocache = atoi(value); | 78 | ctx.cfg.nocache = atoi(value); |
77 | else if (!strcmp(name, "noplainemail")) | 79 | else if (!strcmp(name, "noplainemail")) |
78 | ctx.cfg.noplainemail = atoi(value); | 80 | ctx.cfg.noplainemail = atoi(value); |
79 | else if (!strcmp(name, "noheader")) | 81 | else if (!strcmp(name, "noheader")) |
80 | ctx.cfg.noheader = atoi(value); | 82 | ctx.cfg.noheader = atoi(value); |
81 | else if (!strcmp(name, "snapshots")) | 83 | else if (!strcmp(name, "snapshots")) |
82 | ctx.cfg.snapshots = cgit_parse_snapshots_mask(value); | 84 | ctx.cfg.snapshots = cgit_parse_snapshots_mask(value); |
83 | else if (!strcmp(name, "enable-index-links")) | 85 | else if (!strcmp(name, "enable-index-links")) |
84 | ctx.cfg.enable_index_links = atoi(value); | 86 | ctx.cfg.enable_index_links = atoi(value); |