remove "index" feature - saait - the most boring static page generator
(HTM) git clone git://git.codemadness.org/saait
(DIR) Log
(DIR) Files
(DIR) Refs
(DIR) README
(DIR) LICENSE
---
(DIR) commit d641547794fb688746b5a12bc6acc1ce36b7c33f
(DIR) parent 1f2bea100210ce5dab1d3801efa0968b89020f31
(HTM) Author: Hiltjo Posthuma <hiltjo@codemadness.org>
Date: Sat, 15 Feb 2020 00:12:34 +0100
remove "index" feature
it can be done in a more flexible way by simply a symlink and
specifying/omitting config files.
Diffstat:
M saait.c | 6 ------
1 file changed, 0 insertions(+), 6 deletions(-)
---
(DIR) diff --git a/saait.c b/saait.c
@@ -514,10 +514,6 @@ main(int argc, char *argv[])
for (i = argi; i < (size_t)argc; i++) {
c = readconfig(argv[i]);
- setvar(&c, newvar("index", "1"), 0);
- v = getvar(c, "index");
- doindex = (!v || strcmp(v->value, "0"));
-
if ((p = strrchr(argv[i], '.')))
r = snprintf(htmlfile, sizeof(htmlfile), "%.*s.html",
(int)(p - argv[i]), argv[i]);
@@ -566,8 +562,6 @@ main(int argc, char *argv[])
}
fclose(templates[j].fp);
} else {
- if (!doindex)
- continue; /* do not include in index */
b = &templates[j].blocks[BlockItem];
writepage(templates[j].fp, b->name, argv[i], c,
b->data);