mirror of
https://git.zx2c4.com/cgit
synced 2025-08-02 00:54:36 +02:00
Add support for "robots" meta-tag
With this change, cgit will start to generate the "robots" meta-tag, using a default value of "index, nofollow". The default value can be modified with a new cgitrc variable, "robots". Signed-off-by: Lars Hjemli <hjemli@gmail.com>
This commit is contained in:
parent
1b7c5b2e0b
commit
d267d88c9c
4 changed files with 11 additions and 0 deletions
|
@ -364,6 +364,8 @@ void cgit_print_docstart(char *title, struct cacheitem *item)
|
|||
html_txt(title);
|
||||
html("</title>\n");
|
||||
htmlf("<meta name='generator' content='cgit %s'/>\n", cgit_version);
|
||||
if (cgit_robots && *cgit_robots)
|
||||
htmlf("<meta name='robots' content='%s'/>\n", cgit_robots);
|
||||
html("<link rel='stylesheet' type='text/css' href='");
|
||||
html_attr(cgit_css);
|
||||
html("'/>\n");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue