Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2sharp.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrendan Forster <brendan@github.com>2014-08-20 08:42:08 +0400
committerBrendan Forster <brendan@github.com>2014-08-20 08:42:08 +0400
commita024903d5e2ed42205cc033e09b431a083298cf4 (patch)
tree62bb887ba2ebd03eb0361ab6b7c0a2e8d2832459
parent5c3e9ca49e34b85e53958db60e1a658ff342f00d (diff)
added a secondary function which drops the DiffModifier.IncludeIgnored flagghfw-stage-exclude-ignored
-rw-r--r--LibGit2Sharp/Index.cs18
1 files changed, 18 insertions, 0 deletions
diff --git a/LibGit2Sharp/Index.cs b/LibGit2Sharp/Index.cs
index 35ac45de..01532ee4 100644
--- a/LibGit2Sharp/Index.cs
+++ b/LibGit2Sharp/Index.cs
@@ -189,6 +189,24 @@ namespace LibGit2Sharp
}
/// <summary>
+ /// Promotes to the staging area the latest modifications of a collection of files in the working directory (addition, updation or removal)
+ /// BUT DON'T DIFF IGNORED FILES BECAUSE FILE PATHS MIGHT BE SUPER TERRIBLE.
+ /// </summary>
+ /// <param name="paths">The collection of paths of the files within the working directory.</param>
+ /// <param name="explicitPathsOptions">
+ /// If set, the passed <paramref name="paths"/> will be treated as explicit paths.
+ /// Use these options to determine how unmatched explicit paths should be handled.
+ /// </param>
+ /// <remarks>kids don't try this at home</remarks>
+ public virtual void StageExcludeIgnored(IEnumerable<string> paths, ExplicitPathsOptions explicitPathsOptions = null)
+ {
+ Ensure.ArgumentNotNull(paths, "paths");
+
+ const DiffModifiers modifiers = DiffModifiers.IncludeUntracked;
+ StageInternal(paths, explicitPathsOptions, modifiers);
+ }
+
+ /// <summary>
/// Removes from the staging area all the modifications of a file since the latest commit (addition, updation or removal).
/// </summary>
/// <param name="path">The path of the file within the working directory.</param>