Commit 571167fc authored by xuwang's avatar xuwang
Browse files

fix(release): keep changelog entries on separate lines; flag untrailered commits



The changelog template ended each entry on a `{% end %}` expression tag, whose
trailing newline GitLab's changelog engine strips — concatenating every entry
onto one line. End the entry on the `{{ commit.reference }}` variable tag (as
GitLab's default template does) and document the gotcha.

Add a release-time preflight that lists feat/fix/perf commits in the range with
no `Changelog:` trailer, so silently-excluded changes are visible before the
confirm prompt. Backfill the already-published 1.1.0 notes: the dropped
gl-set-slack feature under Added plus a Fixed section.

Changelog: fixed
Co-Authored-By: default avatarClaude Opus 4.8 <noreply@anthropic.com>
parent ec97d0fe
Loading
Loading
Loading
Loading
+7 −1
Original line number Diff line number Diff line
@@ -26,13 +26,19 @@ categories:
  other: "Other"

# Link each entry back to its commit and author on the canonical server.
#
# Gotcha: GitLab's changelog template engine drops the newline that immediately
# follows a `{% %}` expression tag. The per-entry line must therefore END on a
# `{{ }}` variable tag (here `{{ commit.reference }}`), not on a `{% end %}` — an
# inline `{% if %}…{% end %}` guard would swallow the newline and run every entry
# onto one line.
template: |
  {% if categories %}
  {% each categories %}
  #### {{ title }}

  {% each entries %}
  - {{ title }}{% if commit.reference %} ({{ commit.reference }}){% end %}
  - {{ title }} ({{ commit.reference }})
  {% end %}

  {% end %}
+18 −2
Original line number Diff line number Diff line
@@ -13,10 +13,26 @@ This file is generated at release time from `Changelog:` git trailers (see

#### Added

- feat(agentic): bot-token setup, tmux launcher, reviewer claim, issue-close (iac/cloud-framework@c0b4329d16662d74f09c169a75a6ab7528c841e3)- feat(agentic): add issue→fix→review→merge agent workflow (iac/cloud-framework@60923209900f86e493960fe214947b472616011f)
- feat(agentic): add issue→fix→review→merge agent workflow (iac/cloud-framework@60923209900f86e493960fe214947b472616011f)
- feat(agentic): bot-token setup, tmux launcher, reviewer claim, issue-close (iac/cloud-framework@c0b4329d16662d74f09c169a75a6ab7528c841e3)
- feat(agentic): resolver picks up issues assigned to its bot (iac/cloud-framework@cc2229437e0e629444d719c560a2ad25e687b994)
- feat(gl-set-slack): configure the GitLab for Slack app (per-event channels) (iac/cloud-framework@724b81c47299b5608113ed9c7e695e54e8153c1f)

#### Changed

- feat(agentic): start agents via `claude --bg`; run from a dedicated clone; docs (iac/cloud-framework@2b261789d9cab5a3734019a69149ab0c3cf10aae)- feat(agentic): run multi-identity in `claude agents`; drop tmux launcher (iac/cloud-framework@80de94d8b5cda3af15e0cad8e9da228dfd6ecec8)
- feat(agentic): start agents via `claude --bg`; run from a dedicated clone; docs (iac/cloud-framework@2b261789d9cab5a3734019a69149ab0c3cf10aae)
- feat(agentic): run multi-identity in `claude agents`; drop tmux launcher (iac/cloud-framework@80de94d8b5cda3af15e0cad8e9da228dfd6ecec8)
- feat(agentic): run loop workers under bypass + per-role deny guardrails (iac/cloud-framework@931f8bc87ae8afacac8d8d63eede4e729023ec32)

#### Fixed

- fix: preserve trailing newline in vault-read.sh output (iac/cloud-framework@09e2c5ed121afc87995adc2e1d3ed94e0a60d5d4)
- fix: warn when gl-set-slack targets legacy service on a Slack-app repo (iac/cloud-framework@11db71da5db55a19a8ac3c52bbb237d86fc24960)
- fix(agentic): make agents creates .agentic-logs and records loop launches (iac/cloud-framework@4bc7e872396761a4b430c1189aa452d112615f7e)
- fix(gl-flow): shift once for valueless issue-list flags (iac/cloud-framework@c7194fc792a22bea5e829dbb04124d484d3240f3)
- fix(skill): scope TrimSpace advice to Make-included vault reads (iac/cloud-framework@3aaee668a93aba29c17aa555cbec61e34a266ec2)
- fix(release): require local RELEASE_BRANCH in sync with remote (iac/cloud-framework@cb76b44b574da21164f7a5453a86a3d88f395f24)
- fix(release): compare HEAD to FETCH_HEAD, not the tracking ref (iac/cloud-framework@af2cec6d3388c0b3d40fe2904fb5ee804d2d5534)

## 1.0.1 (2026-06-11)

+24 −0
Original line number Diff line number Diff line
@@ -67,6 +67,30 @@ echo "==> Validating framework (tests/validate.sh all)"
echo "==> Rendering changelog for ${TAG}"
notes=$("${THIS_DIR}/otica-changelog.sh" "${VERSION}")

# ── Preflight: flag likely-changelog commits with no Changelog: trailer ───────
# The changelog API categorizes solely from `Changelog:` trailers, so a commit
# without one is silently dropped from the notes. Surface feat/fix/perf commits
# in the range that lack a trailer so the author can decide before confirming
# (these can't be retro-trailered once tagged without rewriting history).
from_ref=$(git describe --tags --abbrev=0 --match 'v*' 2>/dev/null || true)
range="${from_ref:+${from_ref}..}HEAD"
untrailered=""
while IFS= read -r sha; do
    [ -n "${sha}" ] || continue
    [ -z "$(git show -s --format='%(trailers:key=Changelog,valueonly)' "${sha}")" ] || continue
    subject=$(git show -s --format='%s' "${sha}")
    case "${subject}" in
        feat*|fix*|perf*) untrailered+="  - ${sha:0:9} ${subject}"$'\n' ;;
    esac
done < <(git log --no-merges --format='%H' "${range}")

if [ -n "${untrailered}" ]; then
    echo >&2
    echo "WARNING: feat/fix/perf commits in ${range} with no Changelog: trailer" >&2
    echo "         (excluded from the notes above — add a trailer or proceed knowingly):" >&2
    printf '%s' "${untrailered}" >&2
fi

echo
echo "----------------------------------------------------------------------"
echo "Release ${TAG}  ->  ${REMOTE} (${RELEASE_BRANCH})"