package governance import ( "strings" ) // Development headings cannot replace the formal release baseline. func ExtractDevelopmentNotes(changelog, version string) string { if !SemverValid(version) { return "" } lines := strings.Split(changelog, "\n") prefix := "## 开发快照 snapshot/v" + version + " - " for i, line := range lines { if strings.HasPrefix(line, prefix) { end := len(lines) for j := i + 1; j < len(lines); j++ { if strings.HasPrefix(lines[j], "## ") { end = j break } } return strings.TrimSpace(strings.Join(lines[i+1:end], "\n")) } } return "" }