Skip to content

UnreleasedChangelogConflictResolver

github-actions edited this page Apr 24, 2026 · 1 revision

Rebuilds the active Unreleased section from predictable changelog conflicts.


  • Full name: \FastForward\DevTools\Changelog\Conflict\UnreleasedChangelogConflictResolver
  • This class is marked as final and can't be subclassed
  • This class is a Final class

Methods

__construct

public __construct(\FastForward\DevTools\Changelog\Parser\ChangelogParserInterface $parser, \FastForward\DevTools\Changelog\Renderer\MarkdownRendererInterface $renderer): mixed

Parameters:

Parameter Type Description
$parser \FastForward\DevTools\Changelog\Parser\ChangelogParserInterface
$renderer \FastForward\DevTools\Changelog\Renderer\MarkdownRendererInterface

resolve

Merges source Unreleased entries into the target changelog document.

public resolve(string $targetContents, list<string> $sourceContents, ?string $repositoryUrl = null): string

The target SHOULD be the current base branch changelog. This preserves newly published release sections when a release happened while the pull request branch was waiting, then re-adds branch-only Unreleased entries to the current top-level Unreleased section.

Parameters:

Parameter Type Description
$targetContents string
$sourceContents list
$repositoryUrl ?string

Clone this wiki locally