]> Sergey Matveev's repositories - sgblog.git/blobdiff - cmd/sgblog/gopher-menu.tmpl
Templates translation
[sgblog.git] / cmd / sgblog / gopher-menu.tmpl
index d1cc7ebb939c2b1811adca587672fc0e8bcc9cd1..f27d4b7eb045a452b7bdd503456fa1dd1b73d0cc 100644 (file)
@@ -1,9 +1,9 @@
 {{$CR := printf "\r"}}{{$CRLF := printf "\r\n" -}}
 {{- define "domainPort" }}     {{.GopherDomain}}       70{{end}}{{$Cfg := .Cfg -}}
-i{{.Cfg.Title}} {{if .Topic}}(topic: {{.Topic}}) {{end}}({{.Offset}}-{{.OffsetNext}})  err{{template "domainPort" .Cfg}}{{$CRLF -}}
-{{- if .Cfg.AboutURL}}hAbout   URL:{{.Cfg.AboutURL}}{{template "domainPort" .Cfg}}{{$CRLF}}{{end -}}
-{{- if .Offset}}1Prev  {{if .Topic}}{{.Topic}}/{{end}}offset/{{.OffsetPrev}}{{template "domainPort" .Cfg}}{{$CRLF}}{{end -}}
-{{- if not .LogEnded}}1Next    {{if .Topic}}{{.Topic}}/{{end}}offset/{{.OffsetNext}}{{template "domainPort" .Cfg}}{{$CRLF}}{{end -}}
+i{{.Cfg.Title}} {{if .Topic}}({{$.T.Get "topic"}}: {{.Topic}}) {{end}}({{.Offset}}-{{.OffsetNext}})    err{{template "domainPort" .Cfg}}{{$CRLF -}}
+{{- if .Cfg.AboutURL}}h{{$.T.Get "about"}}     URL:{{.Cfg.AboutURL}}{{template "domainPort" .Cfg}}{{$CRLF}}{{end -}}
+{{- if .Offset}}1{{$.T.Get "prev"}}    {{if .Topic}}{{.Topic}}/{{end}}offset/{{.OffsetPrev}}{{template "domainPort" .Cfg}}{{$CRLF}}{{end -}}
+{{- if not .LogEnded}}1{{$.T.Get "next"}}      {{if .Topic}}{{.Topic}}/{{end}}offset/{{.OffsetNext}}{{template "domainPort" .Cfg}}{{$CRLF}}{{end -}}
 {{- $datePrev := "0001-01-01" -}}
 {{- range .Entries -}}
 {{- $dateCur := .Commit.Author.When.Format "2006-01-02" -}}
@@ -11,6 +11,6 @@ i{{.Cfg.Title}} {{if .Topic}}(topic: {{.Topic}}) {{end}}({{.Offset}}-{{.OffsetNe
 i{{$dateCur}}  err{{template "domainPort" $Cfg}}{{$CR}}{{end}}
 0[{{.Commit.Author.When.Format "15:04"}}] {{.Title}} ({{.LinesNum}}L){{with .CommentsNum}} ({{.}}C){{end}}{{if .Topics}}{{range .Topics}} {{.}}{{end}}{{end}}  /{{.Commit.Hash.String}}{{template "domainPort" $Cfg}}{{$CR}}{{end}}
 {{range .Topics}}
-1Topic: {{.}}  {{.}}/offset/0{{template "domainPort" $Cfg}}{{$CR}}{{end}}
-iGenerated by: SGBlog {{.Version}}     err{{template "domainPort" .Cfg}}{{$CR}}
+1{{$.T.Get "topic"}}: {{.}}    {{.}}/offset/0{{template "domainPort" $Cfg}}{{$CR}}{{end}}
+i{{$.T.Get "Generated by"}}: SGBlog {{.Version}}       err{{template "domainPort" .Cfg}}{{$CR}}
 .{{$CRLF}}