Skip to content
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
6 changes: 6 additions & 0 deletions .changelog/release-pr-version-range.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
---
category: changed
type: patch
---

Shows the current and next versions in automatically prepared release pull request titles.
1 change: 1 addition & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ jobs:

with:
base-branch: main
version-pr-title: 'chore: release {current_version} → {next_version}'
source: tags
comment-mode: always
prepare-release: true
Expand Down
7 changes: 4 additions & 3 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -176,15 +176,16 @@ Changelog parsing, fragments, history and release policy belong to the external
`fast-forward/changelog` package. The workflow caller uses the user-selected
`php-fast-forward/changelog/.github/workflows/changelog.yml@v0` channel and
uses the official README caller with the owner-approved
`name: Fast Forward Changelog` and `publish: true` overrides:
`name: Fast Forward Changelog`, `publish: true` and
`version-pr-title: 'chore: release {current_version} → {next_version}'` overrides:
`base-branch: main`, `source: tags`, `comment-mode: always` and
`prepare-release: true`. Merging the reviewed managed version PR automatically
publishes its tag and GitHub Release at the approved commit. The workflow never
merges the PR itself. This configured publication needs no second per-release
permission; manual publication and changes to existing publications still need
explicit authorization.
Its defaults select Ubuntu, the GitHub token, `changelog/version` and
`chore: update changelog`. Contributions add independent `.changelog/*.md`
Its defaults select Ubuntu, the GitHub token and `changelog/version`; the PR
title is configured above. Contributions add independent `.changelog/*.md`
fragments; do not create a new `Unreleased` section. Automatic PR-origin lookup
uses the library's default enabled policy. Test
history-writing or fragment-consuming operations only in disposable checkouts.
Expand Down
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -279,9 +279,10 @@ workflow that reacts when a pull request becomes ready for review and posts a
deterministic brief for the dedicated review agent.

The external workflow checks fragments and prepares one managed version PR
on `changelog/version`, titled `chore: update changelog`. This repository uses
on `changelog/version`, with the configured title
`chore: release {current_version} → {next_version}`. This repository uses
the official README caller with the explicitly approved
`name: Fast Forward Changelog` and `publish: true` settings: `main`, history
`name: Fast Forward Changelog`, `publish: true` and `version-pr-title` settings: `main`, history
from tags, feedback on every PR and release preparation
enabled. The lifecycle uses its default Ubuntu runner and GitHub token.
Merging the reviewed managed version PR automatically publishes its tag and
Expand Down
6 changes: 4 additions & 2 deletions docs/advanced/consumer-automation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -106,9 +106,11 @@ How Changelog and Project Automation Fit In

- ``.github/workflows/changelog.yml`` calls the external Changelog lifecycle
at ``@v0`` using the official README's single-job caller with the
owner-approved ``name: Fast Forward Changelog`` and ``publish: true`` overrides.
owner-approved ``name: Fast Forward Changelog``, ``publish: true`` and
``version-pr-title`` overrides.
- The external workflow validates contribution fragments and prepares the
``changelog/version`` PR titled ``chore: update changelog``. Publication is
``changelog/version`` PR with the configured title
``chore: release {current_version} → {next_version}``. Publication is
automatic after that reviewed PR is merged. The lifecycle uses its default
Ubuntu runner and GitHub token and never merges the PR itself.
- ``.github/workflows/review.yml`` composes its ready-for-review intake from
Expand Down
6 changes: 4 additions & 2 deletions docs/commands/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,10 @@ The repository caller selects the external workflow's ``@v0`` channel, which
tracks published 0.x releases. Local CPX examples select the latest published
CLI without a version constraint. Resolve the workflow channel and record the
CLI version used when validating release operations; review their compatibility.
The official caller uses ``changelog/version`` and the title
``chore: update changelog``. The Bot owns that branch: let automation
The repository caller uses ``changelog/version`` and configures
``version-pr-title: 'chore: release {current_version} → {next_version}'``.
The placeholders resolve to the current and next versions from the validated
plan. The Bot owns that branch: let automation
regenerate its PR and inspect the new exact head rather than editing the branch
or forging ownership trailers.

Expand Down
4 changes: 2 additions & 2 deletions docs/internals/release-publishing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Version PR and authorization
external ``Fast Forward Changelog`` status plus repository quality gates.
2. Accepted contributions merge into ``main``. The external lifecycle prepares
or regenerates the single managed ``changelog/version`` PR with title
``chore: update changelog``.
configured as ``chore: release {current_version} → {next_version}``.
3. Review the exact new head, planned version, notes, comparison links and
consumed fragment deletions. The Bot owns the branch; do not edit it manually
or fake its transaction evidence. Let automation regenerate after base moves.
Expand All @@ -25,7 +25,7 @@ Version PR and authorization

The caller selects the upstream ``@v0`` channel with the official README
configuration plus the owner-approved ``name: Fast Forward Changelog`` and
``publish: true`` overrides: ``main``,
``publish: true`` and ``version-pr-title`` overrides: ``main``,
historical source ``tags``, feedback ``always`` and release preparation enabled. The external
defaults provide the Ubuntu runner and GitHub token. Local Changelog execution
uses the latest published CLI through CPX and PHP 8.5, without changing the consumer PHP 8.3
Expand Down
6 changes: 4 additions & 2 deletions docs/usage/github-actions.rst
Original file line number Diff line number Diff line change
Expand Up @@ -288,13 +288,15 @@ runner needs Docker, Bash and Git. It does not install the consumer Composer
dependencies or require the consumer to run PHP 8.5.

Both callers use the official README YAML with the owner-approved
``name: Fast Forward Changelog`` and ``publish: true`` overrides and one ``changelog``
``name: Fast Forward Changelog``, ``publish: true`` and ``version-pr-title`` overrides and one ``changelog``
job. They set ``base-branch: main``, ``source: tags``, ``comment-mode: always``,
``prepare-release: true`` and ``publish: true``. The job grants
``contents: write``, ``pull-requests: write``, ``issues: read`` and
``statuses: write``; workflow-level permissions remain empty. The external
defaults select Ubuntu, ``GITHUB_TOKEN``, ``CHANGELOG.md``, ``.changelog``,
``changelog/version`` and the PR title ``chore: update changelog``.
and ``changelog/version``. The callers explicitly configure
``version-pr-title: 'chore: release {current_version} → {next_version}'``;
the library substitutes the validated plan's current and next versions.

Automatic PR-origin lookup uses the external default enabled policy. It
resolves missing origins from committed fragment bytes and merged PR evidence
Expand Down
1 change: 1 addition & 0 deletions resources/github-actions/changelog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ jobs:

with:
base-branch: main
version-pr-title: 'chore: release {current_version} → {next_version}'
source: tags
comment-mode: always
prepare-release: true
Expand Down
1 change: 1 addition & 0 deletions tests/GitHubActions/ChangelogWorkflowTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ public function workflowWillUseTheOfficialSingleJobCallerWithAutomaticPublishing
'uses' => 'php-fast-forward/changelog/.github/workflows/changelog.yml@v0',
'with' => [
'base-branch' => 'main',
'version-pr-title' => 'chore: release {current_version} → {next_version}',
'source' => 'tags',
'comment-mode' => 'always',
'prepare-release' => true,
Expand Down
Loading