Skip to main content

createGithubRepoPushAction()

Home > @backstage/plugin-scaffolder-backend-module-github > createGithubRepoPushAction

Creates a new action that initializes a git repository of the content in the workspace and publishes it to GitHub.

Signature:

function createGithubRepoPushAction(options: {
integrations: ScmIntegrationRegistry;
config: Config;
githubCredentialsProvider?: GithubCredentialsProvider;
}): import("@backstage/plugin-scaffolder-node").TemplateAction<{
repoUrl: string;
description?: string | undefined;
defaultBranch?: string | undefined;
protectDefaultBranch?: boolean | undefined;
protectEnforceAdmins?: boolean | undefined;
gitCommitMessage?: string | undefined;
gitAuthorName?: string | undefined;
gitAuthorEmail?: string | undefined;
requireCodeOwnerReviews?: boolean | undefined;
dismissStaleReviews?: boolean | undefined;
bypassPullRequestAllowances?: {
users?: string[];
teams?: string[];
apps?: string[];
} | undefined;
requiredApprovingReviewCount?: number | undefined;
restrictions?: {
users: string[];
teams: string[];
apps?: string[];
} | undefined;
requiredStatusCheckContexts?: string[] | undefined;
requireBranchesToBeUpToDate?: boolean | undefined;
requiredConversationResolution?: boolean | undefined;
sourcePath?: string | undefined;
token?: string | undefined;
requiredCommitSigning?: boolean | undefined;
}, import("@backstage/types").JsonObject>;

Parameters

ParameterTypeDescription
options{ integrations: ScmIntegrationRegistry; config: Config; githubCredentialsProvider?: GithubCredentialsProvider; }

Returns:

import("@backstage/plugin-scaffolder-node").TemplateAction<{ repoUrl: string; description?: string | undefined; defaultBranch?: string | undefined; protectDefaultBranch?: boolean | undefined; protectEnforceAdmins?: boolean | undefined; gitCommitMessage?: string | undefined; gitAuthorName?: string | undefined; gitAuthorEmail?: string | undefined; requireCodeOwnerReviews?: boolean | undefined; dismissStaleReviews?: boolean | undefined; bypassPullRequestAllowances?: { users?: string[]; teams?: string[]; apps?: string[]; } | undefined; requiredApprovingReviewCount?: number | undefined; restrictions?: { users: string[]; teams: string[]; apps?: string[]; } | undefined; requiredStatusCheckContexts?: string[] | undefined; requireBranchesToBeUpToDate?: boolean | undefined; requiredConversationResolution?: boolean | undefined; sourcePath?: string | undefined; token?: string | undefined; requiredCommitSigning?: boolean | undefined; }, import("@backstage/types").JsonObject>