diff --git a/devtools/hackdoc/markdown.go b/devtools/hackdoc/markdown.go index eaed905c..cfd594da 100644 --- a/devtools/hackdoc/markdown.go +++ b/devtools/hackdoc/markdown.go @@ -19,6 +19,12 @@ func renderMarkdown(input []byte, ref string) []byte { Flags: blackfriday.CommonHTMLFlags | blackfriday.TOC, }) + // master is the default branch - do not make special links for that, as + // that makes them kinda ugly. + if ref == "master" { + ref = "" + } + parser := blackfriday.New(blackfriday.WithRenderer(r), blackfriday.WithExtensions(blackfriday.CommonExtensions)) ast := parser.Parse(input)