feat(release): include aqua-registry updates in changelog and release notes#6623
feat(release): include aqua-registry updates in changelog and release notes#6623
Conversation
… notes This change automatically tracks and displays aqua-registry package updates in both the CHANGELOG.md and GitHub release notes. When the release-plz script updates the aqua-registry, it now: - Captures the before/after package lists - Detects new packages added to the registry - Detects existing packages with updated registry.yaml files - Generates markdown sections with GitHub links for each package - Injects the section into CHANGELOG.md after git-cliff runs - Includes the section in the GitHub PR body The output is formatted with two lists: - New Packages (N): Packages that didn't exist before - Updated Packages (N): Packages where the registry.yaml changed Each package is linked to its GitHub repository for easy reference. Since GitHub release notes are generated from CHANGELOG.md via git-cliff, the aqua-registry updates will automatically appear in release notes too. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
There was a problem hiding this comment.
Pull Request Overview
This PR automatically tracks and displays aqua-registry package updates in both CHANGELOG.md and GitHub release notes by capturing before/after package lists and generating markdown sections with package information.
- Captures package lists before and after aqua-registry updates to detect changes
- Generates markdown sections showing new and updated packages with GitHub links
- Injects aqua-registry updates into CHANGELOG.md and GitHub release PR bodies
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| xtasks/release-plz | Modified to capture package lists, call changelog generation script, and inject aqua updates into changelog and PR bodies |
| scripts/gen-aqua-changelog.sh | New script that compares package lists and generates markdown sections for new and updated packages |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| OLD_AQUA_PKGS="" | ||
| if [[ -d crates/aqua-registry/aqua-registry/pkgs ]]; then | ||
| OLD_AQUA_PKGS="$(find crates/aqua-registry/aqua-registry/pkgs -name registry.yaml -type f | sed 's|crates/aqua-registry/aqua-registry/pkgs/||;s|/registry.yaml||' | sort)" |
There was a problem hiding this comment.
The OLD_AQUA_PKGS capture logic runs before the directory is removed on line 115, but the directory may not exist on first run or clean checkouts, making the logic inconsistent.
| OLD_AQUA_PKGS="" | |
| if [[ -d crates/aqua-registry/aqua-registry/pkgs ]]; then | |
| OLD_AQUA_PKGS="$(find crates/aqua-registry/aqua-registry/pkgs -name registry.yaml -type f | sed 's|crates/aqua-registry/aqua-registry/pkgs/||;s|/registry.yaml||' | sort)" | |
| if [[ -d crates/aqua-registry/aqua-registry/pkgs ]]; then | |
| OLD_AQUA_PKGS="$(find crates/aqua-registry/aqua-registry/pkgs -name registry.yaml -type f | sed 's|crates/aqua-registry/aqua-registry/pkgs/||;s|/registry.yaml||' | sort)" | |
| else | |
| OLD_AQUA_PKGS="" |
| if git diff --quiet HEAD -- "crates/aqua-registry/aqua-registry/pkgs/$pkg/registry.yaml" 2>/dev/null; then | ||
| : # No changes | ||
| else | ||
| UPDATED_PACKAGES+="$pkg"$'\n' |
There was a problem hiding this comment.
Using git diff --quiet HEAD may not work correctly when the aqua-registry directory was just cloned and files are untracked. Consider using git diff --no-index or checking if files are staged first.
| if git diff --quiet HEAD -- "crates/aqua-registry/aqua-registry/pkgs/$pkg/registry.yaml" 2>/dev/null; then | |
| : # No changes | |
| else | |
| UPDATED_PACKAGES+="$pkg"$'\n' | |
| if ! git ls-files --error-unmatch "crates/aqua-registry/aqua-registry/pkgs/$pkg/registry.yaml" >/dev/null 2>&1; then | |
| UPDATED_PACKAGES+="$pkg"$'\n' | |
| elif ! git diff --quiet HEAD -- "crates/aqua-registry/aqua-registry/pkgs/$pkg/registry.yaml"; then | |
| UPDATED_PACKAGES+="$pkg"$'\n' |
| NEW_COUNT=$(echo "$NEW_PACKAGES" | grep -c . || echo "0") | ||
| UPDATED_COUNT=$(echo "$UPDATED_PACKAGES" | grep -c . || echo "0") |
There was a problem hiding this comment.
When variables are empty strings, echo \"\" | grep -c . returns 0 but grep -c can fail with non-zero exit code in some shells. Consider using wc -l instead or ensure the variables contain newlines for accurate counting.
| NEW_COUNT=$(echo "$NEW_PACKAGES" | grep -c . || echo "0") | |
| UPDATED_COUNT=$(echo "$UPDATED_PACKAGES" | grep -c . || echo "0") | |
| NEW_COUNT=$(echo "$NEW_PACKAGES" | wc -l) | |
| UPDATED_COUNT=$(echo "$UPDATED_PACKAGES" | wc -l) |
The grep -c command exits with a non-zero status when there are no matches, causing the script to terminate due to set -e before the || echo "0" fallback can execute. Changed to use || true and explicit zero-check to properly handle the case when there are no new or updated packages.
Hyperfine Performance
|
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.10.6 x -- echo |
18.6 ± 0.5 | 17.7 | 23.8 | 1.00 |
mise x -- echo |
19.1 ± 0.5 | 18.0 | 21.0 | 1.02 ± 0.04 |
mise env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.10.6 env |
18.0 ± 0.3 | 17.2 | 21.2 | 1.00 |
mise env |
18.2 ± 0.3 | 17.3 | 19.6 | 1.01 ± 0.03 |
mise hook-env
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.10.6 hook-env |
17.5 ± 0.5 | 16.4 | 21.6 | 1.00 |
mise hook-env |
17.8 ± 0.6 | 16.4 | 19.8 | 1.02 ± 0.05 |
mise ls
| Command | Mean [ms] | Min [ms] | Max [ms] | Relative |
|---|---|---|---|---|
mise-2025.10.6 ls |
15.7 ± 0.4 | 14.7 | 17.0 | 1.00 |
mise ls |
16.0 ± 0.3 | 15.2 | 17.9 | 1.02 ± 0.03 |
xtasks/test/perf
| Command | mise-2025.10.6 | mise | Variance |
|---|---|---|---|
| install (cached) | 203ms | ✅ 108ms | +87% |
| ls (cached) | 65ms | 65ms | +0% |
| bin-paths (cached) | 72ms | 71ms | +1% |
| task-ls (cached) | 475ms | 478ms | +0% |
✅ Performance improvement: install cached is 87%
Summary
Automatically tracks and displays aqua-registry package updates in both CHANGELOG.md and GitHub release notes.
Changes
When the
xtasks/release-plzscript updates the aqua-registry, it now:registry.yamlfilesOutput Format
The generated sections include two lists:
Each package is linked to its GitHub repository for easy reference.
Example Output
Benefits
✅ Automated - No manual tracking needed
✅ Accurate - Only shows actual changes, not all packages
✅ Linked - Each package links directly to its GitHub repo
✅ Consistent - Follows the existing emoji-based section format
✅ Visibility - Appears in both CHANGELOG.md and GitHub release notes
Implementation Details
scripts/gen-aqua-changelog.shhelper script for better code organizationxtasks/release-plzto call the helper and inject results into CHANGELOG.mdTest plan
🤖 Generated with Claude Code
Note
Automatically detects new/updated aqua-registry packages and injects a linked summary into CHANGELOG.md and the release PR body during the release task.
xtasks/release-plz):scripts/gen-aqua-changelog.sh(usescomm+git diffonpkgs/*/registry.yaml).CHANGELOG.mdaftergit cliffoutput (before first###section of the newest release) usingawk.scripts/gen-aqua-changelog.shWritten by Cursor Bugbot for commit c5b09b5. This will update automatically on new commits. Configure here.