It is possible to clone the repository using 'libgit2sharp'. But I need, only some specific files from the repository. Like search with a filename and then download/save. I tried like below, but failed to find the searched item.
foreach (var item in repository.Commits)
{
var blob = repository.Lookup<Blob>(item.Sha + ":" + fileName);
if (blob == null)
{
continue;
}
else
{
// How to save?
}
}
Also, it is unknown to save file from a 'blob' type. It is just for a download. Not needed for a pull, commit etc in the workflow. Also, a search in the local folder after clone is not a right option in my case. Please advise.
Note: My files are model files(.mdl and .slx).
You can look at the documantation.