stagit

stagit fork for git.lleb.me
git clone git://git.lleb.me/stagit
Log | Files | Refs | README | LICENSE

commit 35e3d38c45f319c203093e38bb6c5c16189edbc8
parent f8df4163febc5e45a4fd6c16dfdd9629e67e8ad8
Author: Daniel <d_nni3l@protonmail.ch>
Date:   Tue, 28 Jul 2020 22:12:32 -0700

Add SVG support 2 + add org name to index 2

Diffstat:
Mstagit-index.c | 9++++++---
1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/stagit-index.c b/stagit-index.c @@ -13,7 +13,8 @@ static git_repository *repo; static const char *relpath = ""; static char description[255] = "git server"; -static char *name = "lleb labs"; +static char org[255] = "lleb labs"; +static char *name = ""; static char owner[255]; void @@ -71,8 +72,10 @@ writeheader(FILE *fp) fprintf(fp, "</title>\n<link rel=\"icon\" type=\"image/png\" href=\"%sfavicon.png\" />\n", relpath); fprintf(fp, "<link rel=\"stylesheet\" type=\"text/css\" href=\"%sstyle.css\" />\n", relpath); fputs("</head>\n<body>\n", fp); - fprintf(fp, "<table>\n<tr><td><img src=\"%slogo.png\" alt=\"\" width=\"32\" height=\"32\" /></td>\n" - "<td><span class=\"desc\">", relpath); + fprintf(fp, "<table>\n<tr><td><img src=\"%slogo.svg\" alt=\"\" width=\"32\" height=\"32\" /></td>\n" + "<td><h1>", relpath); + xmlencode(fp, org, strlen(org)); + fputs("</h1><span class=\"desc\">", fp) xmlencode(fp, description, strlen(description)); fputs("</span></td></tr><tr><td></td><td>\n" "</td></tr>\n</table>\n<hr/>\n<div id=\"content\">\n"