Skip to content

Commit 58be193

Browse files
committed
fix(release-script): recompile examples in the banner step so the hero stamps the bumped version
Render-ReadmeBanner ran `exec:java ReadmeBannerRenderer` without compiling the examples module. banner.properties is filtered to ${project.version} at examples-compile time, and the cut never recompiles examples after the Step-1 version bump — so the re-rendered hero carried the PREVIOUS release version (e.g. a v1.9.0 cut would have stamped "v1.8.0"). Add `compile` to the exec so the module is rebuilt at the bumped version and banner.properties re-filters before the render.
1 parent db8c4f6 commit 58be193

1 file changed

Lines changed: 7 additions & 4 deletions

File tree

scripts/cut-release.ps1

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -344,19 +344,22 @@ function Render-ReadmeBanner {
344344
# Re-renders assets/readme/repository_showcase_render.png straight from the
345345
# engine (DocumentSession.toImage, @since 1.9.0) so the hero's version pill
346346
# carries the just-bumped ${project.version} (read from the filtered
347-
# banner.properties). Runs after Run-ShowcaseSync, which already installed the
348-
# root artifact into the local m2 cache so the examples module resolves it.
347+
# banner.properties). The `compile` is REQUIRED: banner.properties is filtered
348+
# at examples-compile time, so the examples module must be recompiled AFTER the
349+
# Step-1 version bump — otherwise the banner would carry the previous release
350+
# version. Runs after Run-ShowcaseSync, which already installed the bumped root
351+
# artifact into the local m2 cache so the examples module resolves it.
349352
Write-Host " > Re-render the version-stamped README hero banner" -ForegroundColor Cyan
350353
$banner = Join-Path $repoRoot 'assets/readme/repository_showcase_render.png'
351354
$execProp = '"-Dexec.mainClass=com.demcha.examples.support.ReadmeBannerRenderer"'
352355
$execArgs = "`"-Dexec.args=$banner`""
353356
if ($DryRun) {
354-
Write-Host " [DRY RUN] $mvnw -f examples/pom.xml exec:java $execProp $execArgs" -ForegroundColor Yellow
357+
Write-Host " [DRY RUN] $mvnw -f examples/pom.xml -DskipTests compile exec:java $execProp $execArgs" -ForegroundColor Yellow
355358
return
356359
}
357360
Push-Location $repoRoot
358361
try {
359-
& $mvnw -B -ntp -f examples/pom.xml -DskipTests exec:java $execProp $execArgs 2>&1 | ForEach-Object {
362+
& $mvnw -B -ntp -f examples/pom.xml -DskipTests compile exec:java $execProp $execArgs 2>&1 | ForEach-Object {
360363
if ($_ -match 'Rendered README banner|BUILD SUCCESS|BUILD FAILURE|ERROR') {
361364
Write-Host " $_" -ForegroundColor DarkGray
362365
}

0 commit comments

Comments
 (0)