about summary refs log tree commit diff
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--cgit.c2
-rw-r--r--cgit.h1
-rw-r--r--ui-shared.c4
3 files changed, 6 insertions, 1 deletions
diff --git a/cgit.c b/cgit.c
index 64d95f9..2afc598 100644
--- a/cgit.c
+++ b/cgit.c
@@ -31,6 +31,8 @@ void config_cb(const char *name, const char *value)
 		ctx.cfg.favicon = xstrdup(value);
 	else if (!strcmp(name, "footer"))
 		ctx.cfg.footer = xstrdup(value);
+	else if (!strcmp(name, "head-include"))
+		ctx.cfg.head_include = xstrdup(value);
 	else if (!strcmp(name, "header"))
 		ctx.cfg.header = xstrdup(value);
 	else if (!strcmp(name, "logo"))
diff --git a/cgit.h b/cgit.h
index 5f7af51..aed826a 100644
--- a/cgit.h
+++ b/cgit.h
@@ -136,6 +136,7 @@ struct cgit_config {
 	char *css;
 	char *favicon;
 	char *footer;
+	char *head_include;
 	char *header;
 	char *index_header;
 	char *index_info;
diff --git a/ui-shared.c b/ui-shared.c
index de77bbf..fea2c40 100644
--- a/ui-shared.c
+++ b/ui-shared.c
@@ -496,8 +496,10 @@ void cgit_print_docstart(struct cgit_context *ctx)
 		html_attr(cgit_hosturl());
 		html_attr(cgit_fileurl(ctx->repo->url, "atom", ctx->qry.path,
 				       fmt("h=%s", ctx->qry.head)));
-		html("' type='application/atom+xml'/>");
+		html("' type='application/atom+xml'/>\n");
 	}
+	if (ctx->cfg.head_include)
+		html_include(ctx->cfg.head_include);
 	html("</head>\n");
 	html("<body>\n");
 	if (ctx->cfg.header)
home/.config/git/config?id=8ce30925290e0e5c7ebbe6d68b12ad8aa5a6ab09&follow=1'>Set push.autoSetupRemoteJune McEnroe 2022-07-08Remove TOURJune McEnroe 2022-07-03Add The Bone Shard EmperorJune McEnroe 2022-06-25Bump xterm font size to 12June McEnroe 2022-06-10Handle subshells (and functions) inside substitutionsJune McEnroe 2022-06-10Switch to jorts Install scriptJune McEnroe 2022-06-08Indicate if still reading or no resultsJune McEnroe 2022-06-08Add Maiden, Mother, CroneJune McEnroe 2022-06-05FIRST SHOW IN 2.5 YEARS BABEY!!!June McEnroe 2022-06-03Set line number on File linesJune McEnroe 2022-06-03Stop polling stdin after EOFJune McEnroe 2022-06-02Set TABSIZE=4June McEnroe 2022-06-02Do basic match highlightingJune McEnroe 2022-06-02Clean up parsing a littleJune McEnroe 2022-06-02Don't duplicate path stringJune McEnroe 2022-06-02Use stderr instead of /dev/tty, realloc buffer if lines too longJune McEnroe 2022-06-02Add initial working version of qfJune McEnroe 2022-05-29Set prompt for okshJune McEnroe