diff --git a/LibGit2Sharp/Diff.cs b/LibGit2Sharp/Diff.cs
index d18b6b0f8..88c1fdcfc 100644
--- a/LibGit2Sharp/Diff.cs
+++ b/LibGit2Sharp/Diff.cs
@@ -53,6 +53,10 @@ private static GitDiffOptions BuildOptions(DiffModifiers diffOptions, FilePath[]
{
options.Flags |= GitDiffOptionFlags.GIT_DIFF_PATIENCE;
}
+ else if (compareOptions.Algorithm == DiffAlgorithm.Minimal)
+ {
+ options.Flags |= GitDiffOptionFlags.GIT_DIFF_MINIMAL;
+ }
if (diffOptions.HasFlag(DiffModifiers.DisablePathspecMatch))
{
diff --git a/LibGit2Sharp/DiffAlgorithm.cs b/LibGit2Sharp/DiffAlgorithm.cs
index 9e89e68e6..17f173367 100644
--- a/LibGit2Sharp/DiffAlgorithm.cs
+++ b/LibGit2Sharp/DiffAlgorithm.cs
@@ -10,6 +10,11 @@ public enum DiffAlgorithm
///
Meyers = 0,
+ ///
+ /// Use "minimal diff" algorithm when generating patches.
+ ///
+ Minimal = 1,
+
///
/// Use "patience diff" algorithm when generating patches.
///