From 6e2f48e24b0c003b4c8547ff88fc1a7f890a1c1e Mon Sep 17 00:00:00 2001 From: Rory& Date: Thu, 11 Dec 2025 18:54:56 +0100 Subject: read indexes and packs correctly --- LibGitTest/FileRepoSource.cs | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'LibGitTest/FileRepoSource.cs') diff --git a/LibGitTest/FileRepoSource.cs b/LibGitTest/FileRepoSource.cs index 09ec836..94d767f 100644 --- a/LibGitTest/FileRepoSource.cs +++ b/LibGitTest/FileRepoSource.cs @@ -7,10 +7,16 @@ public class FileRepoSource : IRepoSource public FileRepoSource(string basePath) { BasePath = basePath; + if (!Directory.Exists(BasePath)) Console.WriteLine("Warning: Base path does not exist: " + BasePath); } public string BasePath { get; set; } + public async Task FileExists(string path) + { + return File.Exists(Path.Join(BasePath, path)); + } + public async Task GetFileStream(string path) { return File.OpenRead(Path.Join(BasePath, path)); -- cgit 1.5.1