Table of Contents

Struct OptionalSecret

Namespace
DotNetDo
Assembly
DotNetDo.Core.dll

An optional string parameter that masks its value in text and logs.

public readonly record struct OptionalSecret : IEquatable<OptionalSecret>

Properties

Description

Human-readable help text supplied by the task author.

public string? Description { get; }

Property Value

string?

Name

The parameter name, or null when constructed directly.

public string? Name { get; }

Property Value

string?

Methods

QuotedArgument()

Renders the resolved optional secret value as one quoted command-line argument.

public string? QuotedArgument()

Returns

string?

Required()

Converts the optional parameter to its required form, prompting with masked input during an interactive local build or throwing when no value is available.

public Secret Required()

Returns

Secret

ToString()

Returns the fully qualified type name of this instance.

public override string ToString()

Returns

string

The fully qualified type name.

Unwrap()

Returns the plaintext secret value; callers must avoid writing it to unredacted output.

public string? Unwrap()

Returns

string?