stagit

static git page - forked from git.codemadness.org/stagit
git clone git://src.gearsix.net/stagit
Log | Files | Refs | Atom | README | LICENSE

commit a7b0dac923c8535d091105d2921de886b4110b3b
parent b627be363892c3b6d4116a4d5b14a9686c99b895
Author: gearsix <gearsix@tuta.io>
Date:   Thu, 15 Apr 2021 23:48:39 +0100

visual changes to HTML on stagit-index

Diffstat:
Mstagit-index.c | 12+++++-------
Mstagit.c | 2+-
Mstyle-gearsix.css | 7+++++--
3 files changed, 11 insertions(+), 10 deletions(-)

diff --git a/stagit-index.c b/stagit-index.c @@ -15,7 +15,7 @@ static git_repository *repo; static const char *rootpath = "/"; static const char *relpath = ""; -static char description[255] = "gearsix repositories"; +static char description[255] = "git gearsix"; static char *name = "gearsix"; static char *contact = "gearsix@tuta.io"; static char owner[255]; @@ -76,12 +76,10 @@ writeheader(FILE *fp) fprintf(fp, "</title>\n<link rel=\"icon\" type=\"image/png\" href=\"%sfavicon.png\" />\n", rootpath); fprintf(fp, "<link rel=\"stylesheet\" type=\"text/css\" href=\"%sstyle.css\" />\n", rootpath); fputs("</head><body>\n", fp); - fprintf(fp, "<table>\n<tr><td id=\"logo\"><img src=\"%slogo.png\" alt=\"\" width=\"49\" height=\"50\" /></td>\n" - "<td><span class=\"desc\">", rootpath); - xmlencode(fp, description, strlen(description)); - fputs("</span>", fp); - if (contact && strlen(contact) > -1) { - fprintf(fp, "<br/><span class=\"contact\"><b>contact:</b> %s</span>", contact); + fprintf(fp, "<table>\n<tr><td id=\"logo\"><img src=\"%slogo.png\" alt=\"\" width=\"50\" height=\"50\" /></td>\n" + "<td><h2>%s</h2>", rootpath, description); + if (contact && strlen(contact) > 0) { + fprintf(fp, "<span class=\"contact\"><b>contact:</b> <author>%s</author></span>", contact); } fputs("</td></tr>\n</table>\n<hr/>\n<div id=\"content\">\n", fp); } diff --git a/stagit.c b/stagit.c @@ -1258,7 +1258,7 @@ main(int argc, char *argv[]) if (strlen(description) == 0) snprintf(forked, 127, "forked from <a href=\"%s\">%s</a>", url, url); else - snprintf(forked, 127, ", forked from <a href=\"%s\">%s</a>", url, url); + snprintf(forked, 127, "- forked from <a href=\"%s\">%s</a>", url, url); } } diff --git a/style-gearsix.css b/style-gearsix.css @@ -12,8 +12,8 @@ a { a:hover { text-shadow: 1px 1px 5px #8dc; } -h1 { - margin-bottom: 0; +h1, h2 { + margin: 0; } #logo { vertical-align: bottom; @@ -36,3 +36,6 @@ pre { .line { text-decoration: none; } +details { + margin-bottom: 2em; +}