home | blog | art | git gpg | email | rss

stagit

Personal fork of stagit (https://git.codemadness.org/stagit/)
git clone git://pollux.codes/git/stagit
Log | Files | Refs | README | LICENSE
commit 2f1880ba02821ceae00973d9f42d38fce23d30a6
parent 08239dcbc62810f00e261c58f169e7c64aa0a929
Author: Pollux <pollux@pollux.codes>
Date:   Sat, 18 Jan 2025 10:45:36 -0600

feat: remove owner column from index

Signed-off-by: Pollux <pollux@pollux.codes>

Diffstat:
Mstagit-index.c | 20+-------------------
1 file changed, 1 insertion(+), 19 deletions(-)

diff --git a/stagit-index.c b/stagit-index.c @@ -14,7 +14,6 @@ static const char *relpath = ""; static char description[255] = "Repositories"; static char *name = ""; -static char owner[255]; /* Handle read or write errors for a FILE * stream */ void @@ -110,7 +109,7 @@ writeheader(FILE *fp) fputs("</span></td></tr><tr><td></td><td>\n" "</td></tr>\n</table>\n<hr/>\n<div id=\"content\">\n" "<table id=\"index\"><thead>\n" - "<tr><td><b>Name</b></td><td><b>Description</b></td><td><b>Owner</b></td>" + "<tr><td><b>Name</b></td><td><b>Description</b></td>" "<td><b>Last commit</b></td></tr>" "</thead><tbody>\n", fp); } @@ -156,8 +155,6 @@ writelog(FILE *fp) fputs("</a></td><td>", fp); xmlencode(fp, description, strlen(description)); fputs("</td><td>", fp); - xmlencode(fp, owner, strlen(owner)); - fputs("</td><td>", fp); if (author) printtimeshort(fp, &(author->when)); fputs("</td></tr>", fp); @@ -229,21 +226,6 @@ main(int argc, char *argv[]) checkfileerror(fp, "description", 'r'); fclose(fp); } - - /* read owner or .git/owner */ - joinpath(path, sizeof(path), repodir, "owner"); - if (!(fp = fopen(path, "r"))) { - joinpath(path, sizeof(path), repodir, ".git/owner"); - fp = fopen(path, "r"); - } - owner[0] = '\0'; - if (fp) { - if (!fgets(owner, sizeof(owner), fp)) - owner[0] = '\0'; - checkfileerror(fp, "owner", 'r'); - fclose(fp); - owner[strcspn(owner, "\n")] = '\0'; - } writelog(stdout); } writefooter(stdout);