Class FindGitRepositoryRootTask
- Namespace
- Steeltoe.Management.GitProperties.Build
- Assembly
- Steeltoe.Management.GitProperties.Build.dll
Walks up from StartDirectory looking for a ".git" directory (a regular repository) or file (used by worktrees and submodules).
public sealed class FindGitRepositoryRootTask : Task, ITask
- Inheritance
-
FindGitRepositoryRootTask
- Implements
- Inherited Members
Properties
CommonGitDirectory
Gets or sets the directory that holds "config", "packed-refs", and "refs".
[Output]
public string CommonGitDirectory { get; set; }
Property Value
EnableWarnings
Gets or sets a value indicating whether a forgivable anomaly is reported as a warning (true) or an informational message (false).
[Required]
public bool EnableWarnings { get; set; }
Property Value
HeadGitDirectory
Gets or sets the directory that holds "HEAD".
[Output]
public string HeadGitDirectory { get; set; }
Property Value
RepositoryRoot
Gets or sets the resolved repository root, or empty when none was found.
[Output]
public string RepositoryRoot { get; set; }
Property Value
StartDirectory
Gets or sets the directory to start walking up from.
[Required]
public string StartDirectory { get; set; }
Property Value
SuppressGitRepositoryNotFound
Gets or sets a value indicating whether to suppress the diagnostic that no usable .git directory was found.
[Required]
public bool SuppressGitRepositoryNotFound { get; set; }
Property Value
Methods
Execute()
Must be implemented by derived class.
public override bool Execute()
Returns
- bool
true, if successful