aboutsummaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorRunxi Yu <me@runxiyu.org>2025-02-10 10:56:30 +0800
committerRunxi Yu <me@runxiyu.org>2025-02-10 10:56:30 +0800
commit9a73af056287ad19881667c88c687e2864cfa363 (patch)
tree8faca2c2de6aea40376215f703a8627545fc787d /templates
parentrepo_tree_dir: Fix path_spec (diff)
downloadforge-9a73af056287ad19881667c88c687e2864cfa363.tar.gz
forge-9a73af056287ad19881667c88c687e2864cfa363.tar.zst
forge-9a73af056287ad19881667c88c687e2864cfa363.zip
repo_tree: Display files too
Diffstat (limited to 'templates')
-rw-r--r--templates/repo_tree_file.html15
1 files changed, 15 insertions, 0 deletions
diff --git a/templates/repo_tree_file.html b/templates/repo_tree_file.html
new file mode 100644
index 0000000..0df9216
--- /dev/null
+++ b/templates/repo_tree_file.html
@@ -0,0 +1,15 @@
+{{- define "repo_tree_file" -}}
+<!DOCTYPE html>
+<html>
+<head>
+<link rel="stylesheet" href="/static/style.css" />
+<title>{{ .project_name }}/repos/{{ .repo_name }}/{{ .path_spec }}</title>
+</head>
+<body class="repo-index">
+<p>
+/{{ .path_spec }}
+</p>
+<pre>{{ .file_contents }}</pre>
+</body>
+</html>
+{{- end -}}