feat: link each changelog entry to its PR and commit
CI / Checks (pull_request) Successful in 23s
PR title / Conventional title (pull_request) Successful in 2s

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
kebandClaude Opus 5.5 committed 2026-10-11 11:08:25 +02:00
1 parent 1c8d69d957
commit 718e2f881e
3 files changed
+17 -2

No files matched your search

+6 -1
View File
@@ -22,6 +22,7 @@ import (
"os/exec"
"path"
"path/filepath"
"regexp"
"runtime"
"strings"
"time"
@@ -49,9 +50,13 @@ type Release struct {
// every release ends with.
func (r Release) Notes() string {
notes, _, _ := strings.Cut(r.Body, "## Install")
return strings.TrimSpace(notes)
return mdLink.ReplaceAllString(strings.TrimSpace(notes), "$1")
}
// mdLink is a Markdown link, [text](url): the notes link PRs and commits,
// and a terminal shows them as their text.
var mdLink = regexp.MustCompile(`\[([^\]]+)\]\((https?://[^)\s]+)\)`)
// Client talks to the release server.
type Client struct {
API string // the repository's API, DefaultAPI when empty