Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

📖 Update instructions to generate release notes #9957

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 7 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -1098,15 +1098,19 @@ release-alias-tag: ## Add the release alias tag to the last build tag

.PHONY: release-notes-tool
release-notes-tool:
go build -o bin/notes -tags tools sigs.k8s.io/cluster-api/hack/tools/release/notes
go build -C hack/tools -o $(ROOT_DIR)/bin/notes -tags tools sigs.k8s.io/cluster-api/hack/tools/release/notes

.PHONY: release-notes
release-notes: release-notes-tool
./bin/notes --release $(RELEASE_TAG) > CHANGELOG/$(RELEASE_TAG).md

.PHONY: test-release-notes-tool
test-release-notes-tool:
go test -v -tags tools,integration sigs.k8s.io/cluster-api/hack/tools/release/notes
go test -C hack/tools -v -tags tools,integration sigs.k8s.io/cluster-api/hack/tools/release/notes

.PHONY: release-weekly-update-tool
release-weekly-update-tool:
go build -o bin/weekly -tags tools sigs.k8s.io/cluster-api/hack/tools/release/weekly
go build -C hack/tools -o $(ROOT_DIR)/bin/weekly -tags tools sigs.k8s.io/cluster-api/hack/tools/release/weekly

.PHONY: promote-images
promote-images: $(KPROMO)
Expand Down
17 changes: 7 additions & 10 deletions docs/release/release-tasks.md
Original file line number Diff line number Diff line change
Expand Up @@ -350,20 +350,17 @@ The goal of this task is to keep the CAPI community updated on recent PRs that h

#### Create PR for release notes
1. Checkout the `main` branch.
1. Build the release note tools binary.
```bash
make release-notes-tool
```
1. Checkout the latest commit on the release branch, e.g. `release-1.6`, or the main branch if the release branch doesn't yet exist (e.g. beta release).
1. Generate release notes with:

```bash
# PREVIOUS_TAG should be the last patch release of the previous minor release.
PREVIOUS_TAG=v1.5.x
# RELEASE_TAG should be the new desired tag (note: at this point the tag does not yet exist).
RELEASE_TAG=v1.6.x
# If this is a beta or RC release, add the --pre-release-version flag
./bin/notes --from=$PREVIOUS_TAG > CHANGELOG/${RELEASE_TAG}.md
RELEASE_TAG=v1.6.x make release-notes
```

If this is a beta or RC release, add the --pre-release-version flag
```bash
make release-notes-tool
./bin/notes --release=${RELEASE_TAG} --pre-release-version > CHANGELOG/${RELEASE_TAG}.md
```

1. This will generate a new release notes file at `CHANGELOG/<RELEASE_TAG>.md`. Finalize the release notes:
Expand Down