public string Cat(string repoName, string path) { var repoPath = RepositoriesRoot + "/" + repoName; var subPath = "/" + path; var result = SystemProcess.Execute("svnlook", false, $"cat {repoPath} {subPath}"); if (result.exitCode != 0) { throw new Exception(string.Join("\r\n", result.errBuffer)); } return string.Join("\r\n", result.outBuffer); }
public SvnList List(string repoName, string path) { var listPath = FileSchemeRepositoriesRoot + "/" + repoName + "/" + path; var result = SystemProcess.Execute("svn", false, $"list --xml \"{listPath}\""); var combinedResult = string.Join("\r\n", result.outBuffer); var lists = DeserializeXml<SvnLists>(combinedResult); return lists.Lists[0]; }
public bool IsRepository(string name) { var result = SystemProcess.Execute("svnlook", false, $"info {Path.Combine(RepositoriesRoot, name)}"); return result.exitCode == 0; }