pub fn patch_edit(patch: &str, cwd: &Path) -> Option<Value>Expand description
One apply_patch as the canonical edit: the first file the patch names (*** Add|Update|Delete File:) as file_path with its added lines as new_string, each further file in edits the same
way. A rename (*** Move to: after an Update) names its destination as a further file, which gets
the hunk’s added lines. Headers are matched on the trimmed line, as Codex does. Relative paths are
taken from cwd. None for a patch naming no file.