aboutsummaryrefslogtreecommitdiffstats
path: root/shared.c
diff options
context:
space:
mode:
authorGravatar Michael Krelin <hacker@klever.net>2007-07-22 01:00:53 (JST)
committerGravatar Michael Krelin <hacker@klever.net>2007-07-22 01:00:53 (JST)
commitdc3c9b5bc48779f37f2fbcbadce8865eaf4a360e (patch)
treee42607f85bfb3ca33dff761a3966c502cdd6868e /shared.c
parent97c025ae8ecf9764fd6996c81c51c3de4adb837c (diff)
downloadcgit-dc3c9b5bc48779f37f2fbcbadce8865eaf4a360e.zip
cgit-dc3c9b5bc48779f37f2fbcbadce8865eaf4a360e.tar.gz
allow selective enabling of snapshots
snapshot configuration parameter now can be a space/slash/comma/colon/semicolon/pipe-separated list of snaphot suffixes as listed in ui-snapshot.c Signed-off-by: Michael Krelin <hacker@klever.net>
Diffstat (limited to 'shared.c')
-rw-r--r--shared.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/shared.c b/shared.c
index 65fc8b2..ccbde27 100644
--- a/shared.c
+++ b/shared.c
@@ -155,7 +155,7 @@ void cgit_global_config_cb(const char *name, const char *value)
155 else if (!strcmp(name, "nocache")) 155 else if (!strcmp(name, "nocache"))
156 cgit_nocache = atoi(value); 156 cgit_nocache = atoi(value);
157 else if (!strcmp(name, "snapshots")) 157 else if (!strcmp(name, "snapshots"))
158 cgit_snapshots = atoi(value); 158 cgit_snapshots = cgit_parse_snapshots_mask(value);
159 else if (!strcmp(name, "enable-index-links")) 159 else if (!strcmp(name, "enable-index-links"))
160 cgit_enable_index_links = atoi(value); 160 cgit_enable_index_links = atoi(value);
161 else if (!strcmp(name, "enable-log-filecount")) 161 else if (!strcmp(name, "enable-log-filecount"))
@@ -197,7 +197,7 @@ void cgit_global_config_cb(const char *name, const char *value)
197 else if (cgit_repo && !strcmp(name, "repo.defbranch")) 197 else if (cgit_repo && !strcmp(name, "repo.defbranch"))
198 cgit_repo->defbranch = xstrdup(value); 198 cgit_repo->defbranch = xstrdup(value);
199 else if (cgit_repo && !strcmp(name, "repo.snapshots")) 199 else if (cgit_repo && !strcmp(name, "repo.snapshots"))
200 cgit_repo->snapshots = cgit_snapshots * atoi(value); 200 cgit_repo->snapshots = cgit_snapshots & cgit_parse_snapshots_mask(value); /* XXX: &? */
201 else if (cgit_repo && !strcmp(name, "repo.enable-log-filecount")) 201 else if (cgit_repo && !strcmp(name, "repo.enable-log-filecount"))
202 cgit_repo->enable_log_filecount = cgit_enable_log_filecount * atoi(value); 202 cgit_repo->enable_log_filecount = cgit_enable_log_filecount * atoi(value);
203 else if (cgit_repo && !strcmp(name, "repo.enable-log-linecount")) 203 else if (cgit_repo && !strcmp(name, "repo.enable-log-linecount"))