ignore empty group

This commit is contained in:
Lunny Xiao 2017-09-04 22:39:51 +08:00
parent 4b29a88de7
commit 488ce553a3
No known key found for this signature in database
GPG Key ID: C3B7C91B632F738A
1 changed files with 4 additions and 0 deletions

View File

@ -186,6 +186,10 @@ func runGenerate(cmd *cli.Context) {
fmt.Printf("## [%s](https://github.com/%s/releases/tag/v%s) - %s\n", config.Repo, milestone, milestone, time.Now().Format("2006-01-02"))
for _, g := range config.Groups {
if len(changelogs[g.Name]) == 0 {
continue
}
fmt.Println("* " + g.Name)
for _, pr := range changelogs[g.Name] {
fmt.Printf(" * %s (#%d)\n", *pr.Title, *pr.Number)