mirror of
https://github.com/go-kratos/kratos.git
synced 2025-01-14 02:33:03 +02:00
style:change (#2022)
This commit is contained in:
parent
ec2e3ab24e
commit
aa6529fb2d
@ -38,8 +38,8 @@ func run(cmd *cobra.Command, args []string) {
|
||||
if version == "dev" {
|
||||
info := api.GetCommitsInfo()
|
||||
fmt.Print(ParseCommitsInfo(info))
|
||||
} else {
|
||||
info := api.GetReleaseInfo(version)
|
||||
fmt.Print(ParseReleaseInfo(info))
|
||||
return
|
||||
}
|
||||
info := api.GetReleaseInfo(version)
|
||||
fmt.Print(ParseReleaseInfo(info))
|
||||
}
|
||||
|
@ -157,11 +157,12 @@ func ParseCommitsInfo(info []CommitInfo) string {
|
||||
case "other":
|
||||
text = "### Others\n"
|
||||
}
|
||||
if len(value) > 0 {
|
||||
md[key] += text
|
||||
for _, value := range value {
|
||||
md[key] += fmt.Sprintf("- %s\n", value)
|
||||
}
|
||||
if len(value) == 0 {
|
||||
continue
|
||||
}
|
||||
md[key] += text
|
||||
for _, value := range value {
|
||||
md[key] += fmt.Sprintf("- %s\n", value)
|
||||
}
|
||||
}
|
||||
return fmt.Sprint(md["break"], md["deps"], md["feat"], md["fix"], md["chore"], md["other"])
|
||||
|
Loading…
Reference in New Issue
Block a user