]> Sergey Matveev's repositories - sgblog.git/blob - cmd/sgblog/http-entry.tmpl
charset is case-insensitive
[sgblog.git] / cmd / sgblog / http-entry.tmpl
1 {{$Cfg := .Cfg}}<!DOCTYPE html>
2 <html>
3 <head>
4         <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
5         <meta name="generator" content="SGBlog {{.Version}}">
6         <title>{{.Title}} ({{.When}})</title>
7         {{with .Cfg.CSS}}<link rel="stylesheet" type="text/css" href="{{.}}">{{end}}
8         {{with .Cfg.Webmaster}}<link rev="made" href="mailto:{{.}}">{{end -}}
9         {{- range .Cfg.GitURLs}}
10         <link rel="vcs-git" href="{{.}}" title="Git repository">{{end}}
11         <link rel="top" href="{{.Cfg.URLPrefix}}/" title="top">
12         <link rel="alternate" title="Comments feed" href="{{.AtomCommentsURL}}" type="application/atom+xml">
13         {{if .Parent}}<link rel="prev" href="{{.Cfg.URLPrefix}}/{{.Parent}}" title="prev">{{end}}
14 </head>
15 <body>
16 {{with .Cfg.AboutURL}}[<a href="{{.}}">about</a>]{{end}}
17 [<a href="{{.Cfg.URLPrefix}}/">index</a>]
18 {{if .Parent}}[<a href="{{.Cfg.URLPrefix}}/{{.Parent}}">prev</a>]{{end}}
19 [<tt><a title="When">{{.When}}</a></tt>]
20 [<tt><a title="What">{{.Commit.Hash.String}}</a></tt>]
21
22 {{if .Topics}}
23 <hr/>
24 Topics: {{range .Topics}}[<tt><a href="{{$Cfg.URLPrefix}}/?topic={{.}}">{{.}}</a></tt>]{{end}}
25 {{end}}
26
27 <hr/>
28 <h2>{{.Title}}</h2>
29 <pre>
30 {{range .Lines}}{{. | lineURLize $Cfg.URLPrefix}}
31 {{end}}</pre>
32 <hr/>
33
34 {{if .NoteLines}}Note:<pre>
35 {{range .NoteLines}}{{. | lineURLize $Cfg.URLPrefix}}
36 {{end}}</pre>
37 <hr/>{{end}}
38
39 {{if .Cfg.CommentsEmail}}[<a href="mailto:{{.Cfg.CommentsEmail}}?subject={{.TitleEscaped}}">leave comment</a>]{{end}}
40
41 <dl>{{range $idx, $comment := .Comments}}
42 <dt><a name="comment{{$idx}}"><a href="#comment{{$idx}}">comment {{$idx}}</a>:</dt>
43 <dd><pre>
44 {{range $comment.HeaderLines}}{{.}}
45 {{end}}{{range $comment.BodyLines}}{{. | lineURLize $Cfg.URLPrefix}}
46 {{end}}</pre></dd>
47 {{end}}</dl>
48
49 </body>
50 </html>