Skip to main content

Module plan

Module plan 

Source
Expand description

Domain policy over a plan document: the decisions, without the I/O.

Everything here is pure and consumes only schema. It exists because the same decisions were being made independently in crates/tui and crates/stack — and had already drifted (ADR 0020).

Structs§

ClassMembers
One shape class, resolved: which hunk stands for it and which it holds.
Dependency
One resolved depends_on edge.
Enumeration
The three git outputs enumeration is built from.
FileView
GroupView
HunkId
A canonical hunk, in memory.
LineCounts
Line totals for a hunk, or any aggregation of hunks.
PlanIndex
A plan document’s id lookups, built and validated once.
ReadingSplit
One group split into what to read and what to defer.
ReviewSource
A resolved review source: where the diff comes from, and what the review is filed under.
ReviewView
The projection. Owned, not borrowing the document, so a session can hold both without becoming self-referential.

Enums§

Deferral
Why the deferred half is deferred. A renderer’s fold line or commit subject depends on this and on nothing else.
Fold
Whether the deferrable half of a group is currently hidden.
RangeSpec
A revision-range spec, parsed. Pure — resolving MergeBase needs a repository, but deciding what the user asked for does not.
Staged
How one file should be staged.

Functions§

alias_path
A redirect: this id’s progress lives under the id named inside.
all_reviewed
Whether a set of hunks — a group’s, a file’s, a directory’s — reads as done.
artefact_dir
Where the pre-group document is left for the model to read, given the git common dir.
attr_marks_generated
Does a check-attr value declare a path generated?
build_view
Build the canonical view.
cache_dir
Everything regenerable, in ONE subtree.
class_is_generated
Whether a class is generated content: every member hunk lives in a file the classification pass marked generated.
classify
Apply classification hints and compute the mechanical partition.
cumulative_state
The stack renderer’s rule: the file’s state after applied of its hunks.
effort_name
The tier’s domain name, identical to its wire value.
final_state
The core tree builder’s rule: the file’s final state, every hunk applied.
generated_files
The paths doc marks generated, prepared once for class_is_generated.
grouping_cache_dir
The grouping cache directory for a repo, given its git common dir.
identity_path
What a review was opened as: the base sha and the head spec as typed.
missing_mode
The one wording for “this file records no mode”, shared by every rule above and by the renderers. It was copied character for character into crates/stack, where a reader could not tell it was the same failure.
parse_range
Parse a..b, a...b, or two separate revs.
plan_hash
A plan document’s content hash — its immutable identity, and what findings record so re-anchoring knows which document they were written against.
reading_split
Split a group into its read and deferred halves.
review_dir
One review’s sidecar directory, given the git common dir.
review_id
A review’s identity: the resolved base sha plus the head spec AS TYPED.
review_id_named
A review the reader named. The name IS the identity, so neither endpoint is in the key: rebase the base or the head and the session survives, the way a pull request survives a force-push because it is an object rather than a range.
review_id_remote
A review of a pull request or merge request (ADR 0029). The request is the identity, the way a name is: no endpoint is in the key, so a force-push reopens the same review. Its own tag byte keeps it out of both other spaces.
reviews_dir
Where every review is filed. The directory is the catalogue: there is no list file beside it that could disagree with what is on disk.
role_name
The ordering role’s domain name, identical to its wire value.
short_oid
An oid abbreviated for display.
zero_hunk_state
A file with NO hunks: what it contributes to a tree.