stagit

static git page generator
git clone git://git.sgregoratto.me/stagit
Log | Files | Refs | README | LICENSE

commit b705413057ae57a02bf7c3f09ac0483cd3666cb8
parent 021201a8580aa75c7301ec3e0c1a359d289a75b7
Author: Stephen Gregoratto <dev@sgregoratto.me>
Date:   Sat, 20 Jul 2019 01:00:27 +1000

remove images, set stylesheet to root dir

Diffstat:
Mstagit-index.c | 6+++---
Mstagit.c | 12+++++-------
2 files changed, 8 insertions(+), 10 deletions(-)

diff --git a/stagit-index.c b/stagit-index.c @@ -75,10 +75,10 @@ writeheader(FILE *fp) "<meta http-equiv=\"Content-Type\" content=\"text/html; charset=UTF-8\" />\n" "<title>", fp); xmlencode(fp, description, strlen(description)); - 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("</title>", fp); + fputs("<link rel=\"stylesheet\" type=\"text/css\" href=\"/style.css\" />\n", fp); fputs("</head>\n<body>\n", fp); - fprintf(fp, "<table>\n<tr><td><img src=\"%slogo.png\" alt=\"\" width=\"32\" height=\"32\" /></td>\n" + fprintf(fp, "<table>\n<tr><td></td>\n" "<td><span class=\"desc\">", relpath); xmlencode(fp, description, strlen(description)); fputs("</span></td></tr><tr><td></td><td>\n" diff --git a/stagit.c b/stagit.c @@ -353,14 +353,12 @@ writeheader(FILE *fp, const char *title) if (description[0]) fputs(" - ", fp); xmlencode(fp, description, strlen(description)); - fprintf(fp, "</title>\n<link rel=\"icon\" type=\"image/png\" href=\"%sfavicon.png\" />\n", relpath); - fprintf(fp, "<link rel=\"alternate\" type=\"application/atom+xml\" title=\"%s Atom Feed\" href=\"%satom.xml\" />\n", + fputs("</title>\n", fp); + fprintf(fp, "<link rel=\"alternate\" type=\"application/atom+xml\" " + "title=\"%s Atom Feed\" href=\"%satom.xml\" />\n", name, relpath); - fprintf(fp, "<link rel=\"stylesheet\" type=\"text/css\" href=\"%sstyle.css\" />\n", relpath); - fputs("</head>\n<body>\n<table><tr><td>", fp); - fprintf(fp, "<a href=\"../%s\"><img src=\"%slogo.png\" alt=\"\" width=\"32\" height=\"32\" /></a>", - relpath, relpath); - fputs("</td><td><h1>", fp); + fputs("<link rel=\"stylesheet\" type=\"text/css\" href=\"/style.css\" />\n", fp); + fputs("</head>\n<body>\n<table><tr><td></td><td><h1>", fp); xmlencode(fp, strippedname, strlen(strippedname)); fputs("</h1><span class=\"desc\">", fp); xmlencode(fp, description, strlen(description));