Skip to main content

get_file_at_parent

Function get_file_at_parent 

Source
pub fn get_file_at_parent(commit: &str, file: &str) -> Result<String>
Expand description

Get file content at parent commit.

Returns the file content as a string, or an empty string if the file doesn’t exist at parent commit.

§Errors

Returns error if git command fails.