diff options
author | Runxi Yu <me@runxiyu.org> | 2025-02-11 19:04:05 +0800 |
---|---|---|
committer | Runxi Yu <me@runxiyu.org> | 2025-02-11 19:04:05 +0800 |
commit | cac176daa985b032f08758ae54c83eea659f9bc3 (patch) | |
tree | cc581bbeaf0ff1f0affcb33a18e19cac12abf2d8 /templates | |
parent | git_misc: Sanitize paths (diff) | |
download | forge-cac176daa985b032f08758ae54c83eea659f9bc3.tar.gz forge-cac176daa985b032f08758ae54c83eea659f9bc3.tar.zst forge-cac176daa985b032f08758ae54c83eea659f9bc3.zip |
repo_commit: Add a commit info page
Diffstat (limited to 'templates')
-rw-r--r-- | templates/repo_commit.html.tmpl | 44 |
1 files changed, 44 insertions, 0 deletions
diff --git a/templates/repo_commit.html.tmpl b/templates/repo_commit.html.tmpl new file mode 100644 index 0000000..03625aa --- /dev/null +++ b/templates/repo_commit.html.tmpl @@ -0,0 +1,44 @@ +{{- define "repo_commit" -}} +<!DOCTYPE html> +<html lang="en"> + <head> + {{ template "head_common" . }} + <title>{{ .group_name }}/repos/{{ .repo_name }} – Lindenii Forge</title> + </head> + <body class="repo-commit"> + <div class="padding-wrapper"> + <table id="commit-info-table"> + <thead> + <tr class="title-row"> + <th colspan="2">Commit {{ .commit_id }}</th> + </tr> + </thead> + <tbody> + <tr> + <th scope="row">Author</th> + <td>{{ .commit_object.Author.Name }} <<a href="mailto:{{ .commit_object.Author.Email }}">{{ .commit_object.Author.Email }}</a>></td> + </tr> + <tr> + <th scope="row">Author Date</th> + <td>{{ .commit_object.Author.When.Format "Mon, 02 Jan 2006 15:04:05 -0700" }}</td> + </tr> + <tr> + <th scope="row">Committer</th> + <td>{{ .commit_object.Committer.Name }} <<a href="mailto:{{ .commit_object.Committer.Email }}">{{ .commit_object.Committer.Email }}</a>></td> + </tr> + <tr> + <th scope="row">Committer Date</th> + <td>{{ .commit_object.Committer.When.Format "Mon, 02 Jan 2006 15:04:05 -0700" }}</td> + </tr> + </tbody> + </table> + <pre>{{ .patch }}</pre> + <p> + </p> + </div> + <footer> + {{ template "footer" . }} + </footer> + </body> +</html> +{{- end -}} |