Skip to main content

get_diff_commits

Function get_diff_commits 

Source
pub fn get_diff_commits(
    _path: &Path,
    _commit1: &str,
    _commit2: &str,
) -> Result<Vec<GitDiffFile>>
Expand description

Gets the git diff between two commits.

§Parameters

  • path: The path to the git repository.
  • commit1: The hash of the first commit.
  • commit2: The hash of the second commit.

§Returns

  • Ok(Vec<GitDiffFile>) with a list of files with changes between the commits.
  • Err(Error) if an error occurred while getting the diff.