Skip to main content

split_by_file

Function split_by_file 

Source
pub fn split_by_file(diff: &str) -> Vec<FileDiff>
Expand description

Splits a flat unified diff at diff --git a/ boundaries.

Returns one FileDiff for each file section found in the input. An empty or whitespace-only input returns an empty Vec.