Skip to content

Commit 8bc4ed6

Browse files
committed
fix(release): limit changelog generation to last aio tag
1 parent 3a79a8b commit 8bc4ed6

File tree

3 files changed

+27
-60
lines changed

3 files changed

+27
-60
lines changed

.github/workflows/release.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,12 @@ jobs:
5454
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5555
RELEASE_VERSION: ${{ steps.version.outputs.release_version }}
5656
run: |
57-
git-cliff --config cliff.toml --tag "${RELEASE_VERSION}" --output CHANGELOG.md
57+
previous_tag="$(python3 scripts/release.py latest-aio-tag)"
58+
if [[ -n "${previous_tag}" ]]; then
59+
git-cliff --config cliff.toml --tag "${RELEASE_VERSION}" "${previous_tag}..HEAD" --output CHANGELOG.md
60+
else
61+
git-cliff --config cliff.toml --tag "${RELEASE_VERSION}" --output CHANGELOG.md
62+
fi
5863
parsed_version="$(python3 scripts/release.py latest-changelog-version)"
5964
if [[ "${parsed_version}" != "${RELEASE_VERSION}" ]]; then
6065
echo "Generated changelog top section ${parsed_version} does not match ${RELEASE_VERSION}" >&2

CHANGELOG.md

Lines changed: 0 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -3,72 +3,14 @@
33
All notable changes to this project will be documented in this file.
44
## v0.6.9-aio.1 - 2026-04-01
55
### Dependency Updates
6-
- Update docker/setup-qemu-action action to v4 (#13)
7-
- Update docker/setup-buildx-action action to v4 (#12)
8-
- Update docker/login-action action to v4 (#11)
9-
- Update docker/build-push-action action to v7 (#10)
10-
- Update non-major infrastructure updates (#9)
11-
- Update ghcr.io/we-promise/sure docker digest to 12f32c0 (#7)
12-
- Pin docker/dockerfile docker tag to 4a43a54 (#6)
136
- Update ghcr.io/we-promise/sure docker digest to 3d899b3 (#21)
147

158

16-
### Documentation
17-
- Write comprehensive binhex-style README and power user configuration reference guide
18-
- Exhaustively map power-user markdown guide to encompass all AI, telemetry, storage, SSO, and encryption advanced features
19-
- Improve README formatting, add deep links to Power User guide sections, and append Star History chart
20-
21-
229
### Features
23-
- Complete XML redesign based on upstream Sure feature parity (AI, Vectors, SMTP)
24-
- Complete XML redesign based on upstream Sure feature parity (AI, Vectors, SMTP, OIDC, Langfuse)
25-
- Exhaustive XML mapping of all upstream env variables including Active Storage, PostHog, encryption salts, and raw external AI configs
26-
- Finalize enterprise standards for sure-aio (healthchecks, nightly scans, and branding)
27-
- Standardize package tags and add release automation (#19)
2810
- Align sure-aio with upstream v0.6.9 self-hosting surface (#23)
2911

3012

3113
### Fixes
32-
- Change default db hosts from local context to generic IP strings
33-
- Restructure s6-overlay v3 dependencies so db migrations safely wait for postgres to be healthy before booting the web/worker process
34-
- Remove duplicate uppercase Sure-AIO.xml file that was orphaned during early generation
35-
- Update build workflow to point to root context and master branch, remove pre-refactor legacy service scripts
36-
- Add missing type and contents.d files for background worker services
37-
- Pin scout and upload actions to full-length SHAs
38-
- Update build-push-action sha pin to valid v6 hash
39-
- Enforce lowercase image tags and optimize scout execution
40-
- Disable load to support multi-platform exports and target scout via registry
41-
- Dynamically resolve postgres version path to fix fatal binary exec errors
42-
- Fix missing token resolution and globalize node24 fallback in sync action
43-
- Enforce strict SYNC_TOKEN and remove unsecured GitHub token fallback
44-
- Fix default startup and add smoke coverage
4514
- Make releases manual and gate heavy workflows
4615

47-
48-
### Maintenance
49-
- Standardize README, add FUNDING.yml, and clean up legacy files
50-
- Add security policy and unraid template sync workflow
51-
- Implement explicit least privilege on GitHub Actions runner
52-
- Enforce author identity in automation
53-
- Revert to verifiable bot identity for non-repudiation
54-
- Pin GitHub actions to strictly verified full-length SHAs
55-
- Replace docker-scout with anchore-grype to avoid authentication issues
56-
- Temporarily remove anchor scan to allow build pipeline completion under strict allowlist
57-
58-
59-
### Other Changes
60-
- Initial commit: Sure-AIO build files and Unraid XML template
61-
- Generalize postgresql package name for base image compatibility
62-
- Security & CI: Fix node24 deprecation and package write permissions
63-
- Feat/security scout renovate (#1)
64-
- Codex/fix default startup (#5)
65-
- Codex/consolidate ci workflows (#14)
66-
- Codex/fix template icons (#15)
67-
- Fix awesome-unraid sync for protected main
68-
- Standardize tags and add release automation
69-
70-
71-
### Refactors
72-
- Fully realize simplelogin-aio methodology by injecting and orchestrating PostgreSQL and Redis natively inside the container via s6-overlay, dropping external DB requirements
73-
7416
<!-- generated by git-cliff -->

scripts/release.py

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
ROOT = pathlib.Path(__file__).resolve().parents[1]
1212
DEFAULT_CHANGELOG = ROOT / "CHANGELOG.md"
1313
DEFAULT_DOCKERFILE = ROOT / "Dockerfile"
14+
AIO_TAG_PATTERN = "v*-aio.*"
1415

1516

1617
def read_upstream_version(dockerfile: pathlib.Path) -> str:
@@ -27,6 +28,19 @@ def git_tags() -> list[str]:
2728
return [line.strip() for line in output.splitlines() if line.strip()]
2829

2930

31+
def latest_aio_release_tag() -> str | None:
32+
completed = subprocess.run(
33+
["git", "describe", "--tags", "--abbrev=0", "--match", AIO_TAG_PATTERN, "HEAD"],
34+
cwd=ROOT,
35+
text=True,
36+
capture_output=True,
37+
)
38+
if completed.returncode != 0:
39+
return None
40+
tag = completed.stdout.strip()
41+
return tag or None
42+
43+
3044
def latest_release_tag(dockerfile: pathlib.Path) -> str | None:
3145
upstream_version = read_upstream_version(dockerfile)
3246
pattern = re.compile(rf"^{re.escape(upstream_version)}-aio\.(\d+)$")
@@ -42,7 +56,7 @@ def latest_release_tag(dockerfile: pathlib.Path) -> str | None:
4256

4357

4458
def has_unreleased_changes(dockerfile: pathlib.Path) -> bool:
45-
latest_tag = latest_release_tag(dockerfile)
59+
latest_tag = latest_aio_release_tag()
4660
if latest_tag is None:
4761
return True
4862
output = subprocess.check_output(["git", "log", "--format=%s", f"{latest_tag}..HEAD"], cwd=ROOT, text=True)
@@ -125,6 +139,7 @@ def main() -> None:
125139
next_parser.add_argument("--dockerfile", type=pathlib.Path, default=DEFAULT_DOCKERFILE)
126140
changes_parser = subparsers.add_parser("has-unreleased-changes")
127141
changes_parser.add_argument("--dockerfile", type=pathlib.Path, default=DEFAULT_DOCKERFILE)
142+
previous_parser = subparsers.add_parser("latest-aio-tag")
128143

129144
latest_parser = subparsers.add_parser("latest-changelog-version")
130145
latest_parser.add_argument("--changelog", type=pathlib.Path, default=DEFAULT_CHANGELOG)
@@ -147,6 +162,11 @@ def main() -> None:
147162
if args.command == "has-unreleased-changes":
148163
print("true" if has_unreleased_changes(args.dockerfile) else "false")
149164
return
165+
if args.command == "latest-aio-tag":
166+
latest_tag = latest_aio_release_tag()
167+
if latest_tag:
168+
print(latest_tag)
169+
return
150170
if args.command == "latest-changelog-version":
151171
print(latest_changelog_version(args.changelog))
152172
return

0 commit comments

Comments
 (0)