nomad

HCL and Docker files for Nomad deployments
git clone https://git.in0rdr.ch/nomad.git
Log | Files | Refs | Pull requests |Archive

0001-feat-add-pr-link.patch (1810B)


      1 From d1184e7a64723df5830f8c9c17ee3f82ef1441df Mon Sep 17 00:00:00 2001
      2 From: Andreas Gruhler <andreas.gruhler@adfinis.com>
      3 Date: Thu, 29 Aug 2024 09:22:24 +0200
      4 Subject: [PATCH 1/2] feat: add pr link
      5 
      6 ---
      7  stagit-index.c | 4 +++-
      8  stagit.c       | 3 ++-
      9  2 files changed, 5 insertions(+), 2 deletions(-)
     10 
     11 diff --git a/stagit-index.c b/stagit-index.c
     12 index 6402296..d128b36 100644
     13 --- a/stagit-index.c
     14 +++ b/stagit-index.c
     15 @@ -12,7 +12,8 @@ static git_repository *repo;
     16  
     17  static const char *relpath = "";
     18  
     19 -static char description[255] = "Repositories";
     20 +static char description[255] = "Repos";
     21 +static char prlink[255] = " | Pull requests at <a href=\"https://pr.in0rdr.ch\">pr.in0rdr.ch</a>";
     22  static char *name = "";
     23  static char owner[255];
     24  
     25 @@ -107,6 +108,7 @@ writeheader(FILE *fp)
     26  	fprintf(fp, "<table>\n<tr><td><img src=\"%slogo.png\" alt=\"\" width=\"32\" height=\"32\" /></td>\n"
     27  	        "<td><span class=\"desc\">", relpath);
     28  	xmlencode(fp, description, strlen(description));
     29 +	fputs(prlink, fp);
     30  	fputs("</span></td></tr><tr><td></td><td>\n"
     31  		"</td></tr>\n</table>\n<hr/>\n<div id=\"content\">\n"
     32  		"<table id=\"index\"><thead>\n"
     33 diff --git a/stagit.c b/stagit.c
     34 index 03f0c09..5d492f6 100644
     35 --- a/stagit.c
     36 +++ b/stagit.c
     37 @@ -537,7 +537,8 @@ writeheader(FILE *fp, const char *title)
     38  	fputs("<tr><td></td><td>\n", fp);
     39  	fprintf(fp, "<a href=\"%slog.html\">Log</a> | ", relpath);
     40  	fprintf(fp, "<a href=\"%sfiles.html\">Files</a> | ", relpath);
     41 -	fprintf(fp, "<a href=\"%srefs.html\">Refs</a>", relpath);
     42 +	fprintf(fp, "<a href=\"%srefs.html\">Refs</a> | ", relpath);
     43 +	fprintf(fp, "<a href=\"https://pr.in0rdr.ch/repos/%s\">Pull requests</a>", strippedname);
     44  	if (submodules)
     45  		fprintf(fp, " | <a href=\"%sfile/%s.html\">Submodules</a>",
     46  		        relpath, submodules);
     47 -- 
     48 2.44.1
     49