summary refs log tree commit diff
path: root/LibGitTest/FileRepoSource.cs
blob: 09ec836ef1561d88971d55505c7fb6c2269ebb5f (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
using LibGit.Interfaces;

namespace LibGitTest;

public class FileRepoSource : IRepoSource
{
    public FileRepoSource(string basePath)
    {
        BasePath = basePath;
    }

    public string BasePath { get; set; }

    public async Task<Stream> GetFileStream(string path)
    {
        return File.OpenRead(Path.Join(BasePath, path));
    }
}