Table of Contents

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

string

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

bool

HeadGitDirectory

Gets or sets the directory that holds "HEAD".

[Output]
public string HeadGitDirectory { get; set; }

Property Value

string

RepositoryRoot

Gets or sets the resolved repository root, or empty when none was found.

[Output]
public string RepositoryRoot { get; set; }

Property Value

string

StartDirectory

Gets or sets the directory to start walking up from.

[Required]
public string StartDirectory { get; set; }

Property Value

string

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

bool

Methods

Execute()

Must be implemented by derived class.

public override bool Execute()

Returns

bool

true, if successful