the repository which powers this website
add embed
bendn 6 weeks ago
parent 6c0c08e · commit 158c043
-rw-r--r--README.md (renamed from README)0
-rw-r--r--themed/base.html13
-rw-r--r--themed/commit.html2
-rw-r--r--themed/diff.html10
-rw-r--r--themed/index.html2
-rw-r--r--themed/log.html2
-rw-r--r--themed/refs.html2
-rw-r--r--themed/summary.html2
-rw-r--r--themed/tree.html2
9 files changed, 23 insertions, 12 deletions
diff --git a/README b/README.md
index 7a6b4a40..7a6b4a40 100644
--- a/README
+++ b/README.md
diff --git a/themed/base.html b/themed/base.html
index 06569739..ff8d3473 100644
--- a/themed/base.html
+++ b/themed/base.html
@@ -1,6 +1,6 @@
{! static int get_num_commits(void); static int get_num_branches(void); static int get_num_tags(void); static void short_commit_id(char *hex); !}
-{% block page_start %}
+{% block page_start(const char* title, const char* description) %}
<!DOCTYPE html>
<html>
<head>
@@ -12,6 +12,13 @@
{! cgit_shared_emit_css_link(NULL, "/themed.css"); !}
{% endif %}
+ <meta property="og:site_name" content="git.bendn.org: github but worser, and prettier">
+ <meta content="{{ title|attr }}" property="og:title" />
+ <meta content="{{ description|attr }}" property="og:description" />
+ <meta content="https://git.bendn.org/" property="og:url" />
+ <meta content="https://git.bendn.org/icons/cgit.png" property="og:image" />
+ <meta content="#1dffd5" data-react-helmet="true" name="theme-color" />
+
<link rel='shortcut icon' href='/favicon.ico'>
</head>
<body class="bg-[#1F2430] text-[#CCCAC2]">
@@ -146,6 +153,10 @@
at
{{ show_date(time(NULL), 0, cgit_date_mode(DATE_ISO8601)) }}
</div>
+ <div class="text-sm text-[#CCCAC2]">
+ problem? patch? question? complaint?
+ email bend dot n on outlook
+ </div>
</div>
</footer>
</body>
diff --git a/themed/commit.html b/themed/commit.html
index 9c535b10..1f610fb8 100644
--- a/themed/commit.html
+++ b/themed/commit.html
@@ -17,7 +17,7 @@
ctx.page.title = fmtalloc("%s - %s", info->subject, ctx.page.title);
!}
-{! page_start(); !}
+{! page_start(ctx.repo->name, fmtalloc("look at commit \"%s\"", info->subject)); !}
{! repo_header(); !}
<main class="max-w-7xl mx-auto py-4 pl-2 pr-2">{# Main content #}
{! repo_description_panel(); !}
diff --git a/themed/diff.html b/themed/diff.html
index 633264dc..2e88e333 100644
--- a/themed/diff.html
+++ b/themed/diff.html
@@ -1,10 +1,10 @@
-{! #include "../ui-diff.h" !} {% page cgit_print_diff_page %} {! page_start();
-!} {! repo_header(); !}
+{! #include "../ui-diff.h" !} {% page cgit_print_diff_page %} {!
+page_start(ctx.repo->name, "diff of latest commit"); !} {! repo_header(); !}
<main class="max-w-[1280px] mx-auto py-4">
{# Main content #} {! repo_description_panel(); !} {! repo_summary_bar(); !}
- <div class="diff-panel overflow-x-auto">
+ <div class="diff-panel overflow-x-auto">
{# Diff panel #} {! cgit_print_diff(ctx.qry.oid, ctx.qry.oid2, ctx.qry.path,
0, 0); !}
- </div>
- </main>
+ </div>
+</main>
{! page_end(); !} {% endpage %}
diff --git a/themed/index.html b/themed/index.html
index 997d367b..faee4886 100644
--- a/themed/index.html
+++ b/themed/index.html
@@ -2,7 +2,7 @@
{% page cgit_print_repolist %}
{! ctx.page.title = ctx.cfg.root_title; !}
-{! page_start(); !}
+{! page_start("bendns' repos", "list of bendns' repos"); !}
<header class="bg-[#262F3F] border-b border-[#333A45]">
{# Repo header #}
<div class="pl-2 max-w-7xl mx-auto py-4 flex gap-x-1 items-center">
diff --git a/themed/log.html b/themed/log.html
index 8446150d..63b151e6 100644
--- a/themed/log.html
+++ b/themed/log.html
@@ -1,5 +1,5 @@
{% page cgit_print_log %}
-{! page_start(); !}
+{! page_start(ctx.repo->name, "commit log"); !}
{! repo_header(); !}
<main class="max-w-7xl mx-auto py-4 pl-2 pr-2">{# Main content #}
{! repo_description_panel(); !}
diff --git a/themed/refs.html b/themed/refs.html
index c5e1b68d..5d7ca71a 100644
--- a/themed/refs.html
+++ b/themed/refs.html
@@ -3,7 +3,7 @@
{! int cgit_refs_cmp_tag_age(const void *a, const void *b); !}
{% page cgit_print_refs %}
-{! page_start(); !}
+{! page_start(ctx.repo->name, "view refs"); !}
{! repo_header(); !}
<main class="max-w-7xl mx-auto py-4">{# Main content #}
{! repo_description_panel(); !}
diff --git a/themed/summary.html b/themed/summary.html
index a18983a6..7d8568b7 100644
--- a/themed/summary.html
+++ b/themed/summary.html
@@ -8,7 +8,7 @@
!}
{% block cgit_print_summary_impl %}
-{! page_start(); !}
+{! page_start(ctx.repo->name, ctx.repo->desc); !}
{! repo_header(); !}
<main class="max-w-7xl mx-auto py-4 pl-2 pr-2">{# Main content #}
{! repo_description_panel(); !}
diff --git a/themed/tree.html b/themed/tree.html
index 516afc17..702841ca 100644
--- a/themed/tree.html
+++ b/themed/tree.html
@@ -133,7 +133,7 @@
// Redirect to summary page if no subdirectory
if (!ctx.qry.path) { return cgit_print_summary_impl(); }
!}
-{! page_start(); !}
+{! page_start(ctx.repo->name, fmtalloc("view file \"%s/%s\"", ctx.repo->name, ctx.qry.path)); !}
{! repo_header(); !}
<main class="max-w-7xl mx-auto py-4 pl-2 pr-2">{# Main content #}
{! repo_description_panel(); !}