34// first use so a normal scc invocation pays nothing for the report path. The
35// returned root template has both "report" and "card" defined.
36▶func reportTemplate() *template.Template {
37 reportTmplOnce.Do(func() {
38 root := template.New("report").Funcs(reportFuncs)
· · ·
37▶ reportTmplOnce.Do(func() {
38 root := template.New("report").Funcs(reportFuncs)
39 reportTmpl = template.Must(root.Parse(reportTemplateSrc))
· · ·
38▶ root := template.New("report").Funcs(reportFuncs)
39 reportTmpl = template.Must(root.Parse(reportTemplateSrc))
40 template.Must(reportTmpl.New("card").Parse(reportCardSrc))
· · ·
49// that future template helpers can surface "you asked for X but it's not a
50// real section" hints without re-parsing.
51▶func parseReportSkip(raw string) {
52 parseReportSkipTo(raw, os.Stderr)
53}
· · ·
56// destination is plumbed through so unit tests can capture stderr output
57// without resorting to os.Stderr redirection.
58▶func parseReportSkipTo(raw string, warnW io.Writer) {
59 ReportSkipNames = map[string]bool{}
60 if strings.TrimSpace(raw) == "" {
+ 47 more matches in this file