Table of Contents

Class RequiredSecretsDetector

Namespace
Ando.Server.Services
Assembly
Ando.Server.dll

Detects required environment variables from build scripts.

public class RequiredSecretsDetector : IRequiredSecretsDetector
Inheritance
RequiredSecretsDetector
Implements
Inherited Members

Constructors

RequiredSecretsDetector(IGitHubService, ILogger<RequiredSecretsDetector>)

public RequiredSecretsDetector(IGitHubService gitHubService, ILogger<RequiredSecretsDetector> logger)

Parameters

gitHubService IGitHubService
logger ILogger<RequiredSecretsDetector>

Methods

DetectRequiredSecretsAsync(long, string, string?)

Detects required environment variables from a repository's build script.

public Task<IReadOnlyList<string>> DetectRequiredSecretsAsync(long installationId, string repoFullName, string? branch = null)

Parameters

installationId long

GitHub App installation ID.

repoFullName string

Repository full name (owner/repo).

branch string

Branch to read from (optional, uses default branch if null).

Returns

Task<IReadOnlyList<string>>

List of detected required environment variable names.

ParseRequiredSecrets(string)

Detects required environment variables from build script content.

public IReadOnlyList<string> ParseRequiredSecrets(string scriptContent)

Parameters

scriptContent string

The content of a build.csando file.

Returns

IReadOnlyList<string>

List of detected required environment variable names.