Skip to main content

git_path_line

Function git_path_line 

Source
pub fn git_path_line(stdout: &[u8]) -> Option<&str>
Expand description

The one path that a git rev-parse path query prints, without the line end that git adds. Only one trailing \n (and a \r before it) goes, so a path that ends in a space or another blank stays the same path. Output that is not UTF-8 returns None: a lossy conversion would name another path.