forked from libgit2/libgit2sharp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathStatusOptions.cs
85 lines (74 loc) · 2.49 KB
/
StatusOptions.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace LibGit2Sharp
{
/// <summary>
/// Flags controlling what files are reported by status.
/// </summary>
public enum StatusShowOption
{
/// <summary>
/// Both the index and working directory are examined for changes
/// </summary>
IndexAndWorkDir = 0,
/// <summary>
/// Only the index is examined for changes
/// </summary>
IndexOnly = 1,
/// <summary>
/// Only the working directory is examined for changes
/// </summary>
WorkDirOnly = 2
}
/// <summary>
/// Options controlling the status behavior.
/// </summary>
public sealed class StatusOptions
{
/// <summary>
/// Initializes a new instance of the <see cref="StatusOptions"/> class.
/// By default, both the index and the working directory will be scanned
/// for status, and renames will be detected from changes staged in the
/// index only.
/// </summary>
public StatusOptions()
{
DetectRenamesInIndex = true;
}
/// <summary>
/// Which files should be scanned and returned
/// </summary>
public StatusShowOption Show { get; set; }
/// <summary>
/// Examine the staged changes for renames.
/// </summary>
public bool DetectRenamesInIndex { get; set; }
/// <summary>
/// Examine unstaged changes in the working directory for renames.
/// </summary>
public bool DetectRenamesInWorkDir { get; set; }
/// <summary>
/// Exclude submodules from being scanned for status
/// </summary>
public bool ExcludeSubmodules { get; set; }
/// <summary>
/// Recurse into ignored directories
/// </summary>
public bool RecurseIgnoredDirs { get; set; }
/// <summary>
/// Limit the scope of paths to consider to the provided pathspecs
/// </summary>
/// <remarks>
/// If a PathSpec is given, the results from rename detection may
/// not be accurate.
/// </remarks>
public string[] PathSpec { get; set; }
/// <summary>
/// When set to <c>true</c>, the PathSpec paths will be considered
/// as explicit paths, and NOT as pathspecs containing globs.
/// </summary>
public bool DisablePathSpecMatch { get; set; }
}
}