diff --git a/src/Commands/Checkout.cs b/src/Commands/Checkout.cs index d65e9e73..a1a151aa 100644 --- a/src/Commands/Checkout.cs +++ b/src/Commands/Checkout.cs @@ -62,6 +62,14 @@ namespace SourceGit.Commands return Exec(); } + public bool Commit(string commitId, Action onProgress) + { + Args = $"checkout --detach --progress {commitId}"; + TraitErrorAsOutput = true; + _outputHandler = onProgress; + return Exec(); + } + public bool Files(List files) { StringBuilder builder = new StringBuilder();