Skip to main content

build_trend

Function build_trend 

Source
pub fn build_trend(
    walked: &[(String, Vec<Record>)],
    head_sha: &str,
    head_records: &[Record],
) -> Trend
Expand description

Assemble a trend from trunk history plus the revision under comparison.

walked is oldest-first, each entry a commit and the records attached to it.

The head’s point is appended only when the walk did not already contain it. Appending unconditionally put it last even when it belongs in the middle — tak compare v1.33.0 --rev v1.30.0 compares against an ancestor, and the line then ended on a value from earlier in the history while reading as though time ran left to right.