File tree Expand file tree Collapse file tree 2 files changed +44
-2
lines changed Expand file tree Collapse file tree 2 files changed +44
-2
lines changed Original file line number Diff line number Diff line change 11## {{.Version}} [ {{.Repo}}-release-notes-{{.Version}}]
2- {{ if or .Feature .Enhancement .Security .BugFix }}
3- {{ if or .Feature .Enhancement }}
2+ {{ if or .KnownIssue .BreakingChange .Deprecation }}
3+ {{ other_links }}{{- end }}
4+ {{ if or .Feature .Enhancement .Security .BugFix }}{{ if or .Feature .Enhancement }}
45### Features and enhancements [ {{.Repo}}-{{.Version}}-features-enhancements]
56{{ if .Feature }}{{ range $k, $v := .Feature }}{{ range $item := $v }}
67* {{ $item.Summary | beautify }} {{ linkPRSource $item.Component $item.LinkedPR }} {{ linkIssueSource $item.Component $item.LinkedIssue }}{{ if $item.Description }}
Original file line number Diff line number Diff line change @@ -128,6 +128,47 @@ func (r Renderer) Render() error {
128128 re := regexp .MustCompile (`\n|\r|^` )
129129 return re .ReplaceAllString (s , "\n " )
130130 },
131+ "other_links" : func () string {
132+ var links []string
133+ if len (td .KnownIssue ) > 0 {
134+ links = append (
135+ links ,
136+ fmt .Sprintf (
137+ "[Known issues](/release-notes/known-issues.md#%s-%s-known-issues)" ,
138+ r .repo ,
139+ r .changelog .Version ,
140+ ),
141+ )
142+ }
143+ if len (td .BreakingChange ) > 0 {
144+ links = append (
145+ links ,
146+ fmt .Sprintf (
147+ "[Breaking changes](/release-notes/breaking-changes.md#%s-%s-breaking-changes)" ,
148+ r .repo ,
149+ r .changelog .Version ,
150+ ),
151+ )
152+ }
153+ if len (td .Deprecation ) > 0 {
154+ links = append (
155+ links ,
156+ fmt .Sprintf (
157+ "[Deprecations](/release-notes/deprecations.md#%s-%s-deprecations)" ,
158+ r .repo ,
159+ r .changelog .Version ,
160+ ),
161+ )
162+ }
163+ if len (links ) > 0 {
164+ return fmt .Sprintf (
165+ "_This release also includes: %s._" ,
166+ strings .Join (links , " and" ),
167+ )
168+ } else {
169+ return ""
170+ }
171+ },
131172 // Ensure components have section styling
132173 "header2" : func (s1 string ) string {
133174 return fmt .Sprintf ("**%s**" , s1 )
You can’t perform that action at this time.
0 commit comments