private int GetLineCount(string hash, TreeEntryMode mode) { if (mode == TreeEntryMode.RegularExecutableFile) { return(0); } string content = repositoryReader.ReadBlob(hash); return(content.Length == 0 ? 0 : content.Count(c => c == '\n') + 1); }
public PathHashMode(string path, string hash, TreeEntryMode mode) { Path = path; Hash = hash; Mode = mode; }