Interface IGitHubSourceProps

Construction properties for GitHubSource and GitHubEnterpriseSource.

Inherited Members
Namespace: Amazon.CDK.AWS.CodeBuild
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public interface IGitHubSourceProps : ISourceProps
Syntax (vb)
Public Interface IGitHubSourceProps Inherits ISourceProps
Examples
var gitHubSource = Source.GitHub(new GitHubSourceProps {
                Owner = "aws",
                WebhookTriggersBatchBuild = true,  // optional, default is false
                WebhookFilters = new [] { FilterGroup.InEventOf(EventAction.WORKFLOW_JOB_QUEUED).AndRepositoryNameIs("aws-.*").AndRepositoryNameIsNot("aws-cdk-lib") }
            });

Synopsis

Properties

BranchOrRef

The commit ID, pull request ID, branch name, or tag name that corresponds to the version of the source code you want to build.

BuildStatusContext

This parameter is used for the context parameter in the GitHub commit status.

BuildStatusUrl

The URL that the build will report back to the source provider.

CloneDepth

The depth of history to download.

FetchSubmodules

Whether to fetch submodules while cloning git repo.

Owner

The GitHub Organization/user that owns the repo.

Repo

The name of the repo (without the username).

ReportBuildStatus

Whether to send notifications on your build's start and end.

Webhook

Whether to create a webhook that will trigger a build every time an event happens in the repository.

WebhookFilters

A list of webhook filters that can constraint what events in the repository will trigger a build.

WebhookTriggersBatchBuild

Trigger a batch build from a webhook instead of a standard one.

Properties

BranchOrRef

The commit ID, pull request ID, branch name, or tag name that corresponds to the version of the source code you want to build.

string? BranchOrRef { get; }
Property Value

string

Examples
"mybranch";

BuildStatusContext

This parameter is used for the context parameter in the GitHub commit status.

string? BuildStatusContext { get; }
Property Value

string

Examples
"My build #$CODEBUILD_BUILD_NUMBER";

BuildStatusUrl

The URL that the build will report back to the source provider.

string? BuildStatusUrl { get; }
Property Value

string

Examples
"$CODEBUILD_PUBLIC_BUILD_URL";

CloneDepth

The depth of history to download.

double? CloneDepth { get; }
Property Value

double?

FetchSubmodules

Whether to fetch submodules while cloning git repo.

bool? FetchSubmodules { get; }
Property Value

bool?

Owner

The GitHub Organization/user that owns the repo.

Property Value

string

Examples
"awslabs";

Repo

The name of the repo (without the username).

Property Value

string

Examples
"aws-cdk";

ReportBuildStatus

Whether to send notifications on your build's start and end.

bool? ReportBuildStatus { get; }
Property Value

bool?

Webhook

Whether to create a webhook that will trigger a build every time an event happens in the repository.

Property Value

bool?

WebhookFilters

A list of webhook filters that can constraint what events in the repository will trigger a build.

FilterGroup[]? WebhookFilters { get; }
Property Value

FilterGroup[]

WebhookTriggersBatchBuild

Trigger a batch build from a webhook instead of a standard one.

bool? WebhookTriggersBatchBuild { get; }
Property Value

bool?