AffectedGraphConfig

abstract class AffectedGraphConfig @Inject constructor(objects: ObjectFactory)(source)

Configures the affected-graph analysis inside the affected { } block.

aalekh {
affected {
baseRef.set("origin/main") // compare against the PR's merge target
headRef.set("HEAD") // ...up to this ref (blank = working tree)
}
}

Drives aalekhAffected, which runs git diff at execution time and writes a local aalekh-affected.md / aalekh-affected.json a CI job can post as a pull-request comment.

Constructors

Link copied to clipboard
@Inject
constructor(objects: ObjectFactory)

Properties

Link copied to clipboard
val baseRef: Property<String>

The base git ref to diff against. Default: "HEAD~1" (the previous commit). Set to the PR's merge target, e.g. "origin/main", in CI.

Link copied to clipboard
val headRef: Property<String>

The head git ref. Blank (the default) diffs baseRef against the working tree; a non-blank value uses the three-dot form baseRef...headRef - changes on head since the merge base.