Skip to content

Commit

Permalink
fix for commit 6f5dc73: set Meta whenever header.tmpl is involved
Browse files Browse the repository at this point in the history
  • Loading branch information
stapelberg committed Jan 21, 2017
1 parent 17e636c commit f8ca751
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 0 deletions.
4 changes: 4 additions & 0 deletions cmd/debiman/renderaux.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"strings"

"github.com/Debian/debiman/internal/bundled"
"github.com/Debian/debiman/internal/manpage"
)

var indexTmpl = mustParseIndexTmpl()
Expand Down Expand Up @@ -56,6 +57,7 @@ func renderAux(destDir string, gv globalView) error {
Breadcrumbs []breadcrumb
FooterExtra string
Suites []string
Meta *manpage.Meta
}{
Title: "index",
Suites: suites,
Expand All @@ -71,6 +73,7 @@ func renderAux(destDir string, gv globalView) error {
DebimanVersion string
Breadcrumbs []breadcrumb
FooterExtra string
Meta *manpage.Meta
}{
Title: "FAQ",
DebimanVersion: debimanVersion,
Expand All @@ -85,6 +88,7 @@ func renderAux(destDir string, gv globalView) error {
DebimanVersion string
Breadcrumbs []breadcrumb
FooterExtra string
Meta *manpage.Meta
}{
Title: "FAQ",
DebimanVersion: debimanVersion,
Expand Down
2 changes: 2 additions & 0 deletions cmd/debiman/rendercontents.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"sort"

"github.com/Debian/debiman/internal/bundled"
"github.com/Debian/debiman/internal/manpage"
)

var contentsTmpl = mustParseContentsTmpl()
Expand All @@ -28,6 +29,7 @@ func renderContents(dest, suite string, bins []string) error {
FooterExtra string
Bins []string
Suite string
Meta *manpage.Meta
}{
Title: fmt.Sprintf("Contents of Debian %s", suite),
DebimanVersion: debimanVersion,
Expand Down
2 changes: 2 additions & 0 deletions cmd/debiman/renderpkgindex.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ func renderPkgindex(dest string, manpageByName map[string]*manpage.Meta) error {
Breadcrumbs []breadcrumb
FooterExtra string
First *manpage.Meta
Meta *manpage.Meta
ManpageByName map[string]*manpage.Meta
Mans []string
}{
Expand All @@ -47,6 +48,7 @@ func renderPkgindex(dest string, manpageByName map[string]*manpage.Meta) error {
{"", "Contents"},
},
First: first,
Meta: first,
ManpageByName: manpageByName,
Mans: mans,
})
Expand Down
2 changes: 2 additions & 0 deletions internal/aux/aux.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import (
"strings"
"sync"

"github.com/Debian/debiman/internal/manpage"
"github.com/Debian/debiman/internal/redirect"
)

Expand Down Expand Up @@ -66,6 +67,7 @@ func (s *Server) HandleRedirect(w http.ResponseWriter, r *http.Request) {
FooterExtra string
Manpage string
BestChoice redirect.IndexEntry
Meta *manpage.Meta
}{
Title: "Not Found",
DebimanVersion: s.debimanVersion,
Expand Down

0 comments on commit f8ca751

Please sign in to comment.