enhance: show git errors when failed to get the repository root dir of given path (#397)

This commit is contained in:
leo
2024-08-27 15:35:10 +08:00
parent 963916219f
commit b16d267c9b
14 changed files with 40 additions and 39 deletions

View File

@@ -6,15 +6,6 @@
{
WorkingDirectory = path;
Args = "rev-parse --show-toplevel";
RaiseError = false;
}
public string Result()
{
var rs = ReadToEnd().StdOut;
if (string.IsNullOrEmpty(rs))
return null;
return rs.Trim();
}
}
}