Added DiffOption constructor to diff two files directly

This commit is contained in:
Henrik Andersson 2025-06-04 10:40:25 +02:00
parent 33470eda19
commit 052132d796

View file

@ -99,6 +99,18 @@ namespace SourceGit.Models
_orgPath = change.OriginalPath;
}
/// <summary>
/// Used to show differences between two files.
/// </summary>
/// <param name="path_lhs"></param>
/// <param name="path_rhs"></param>
public DiffOption(string path_lhs, string path_rhs)
{
_extra = "--no-index";
_orgPath = path_lhs;
_path = path_rhs;
}
/// <summary>
/// Converts to diff command arguments.
/// </summary>