refactor: rename github:repository:webhook:create to github:webhook

Signed-off-by: @pawelmitka <pawel.mitka@brainly.com>
This commit is contained in:
@pawelmitka
2021-08-27 16:34:38 +02:00
parent 8ebd2b6399
commit c5c229966f
4 changed files with 7 additions and 7 deletions
@@ -39,7 +39,7 @@ import {
} from './publish';
import {
createGithubActionsDispatchAction,
createGithubCreateRepositoryWebhookAction,
createGithubWebhookAction,
} from './github';
export const createBuiltinActions = (options: {
@@ -93,7 +93,7 @@ export const createBuiltinActions = (options: {
createGithubActionsDispatchAction({
integrations,
}),
createGithubCreateRepositoryWebhookAction({
createGithubWebhookAction({
integrations,
}),
];
@@ -16,7 +16,7 @@
jest.mock('@octokit/rest');
import { createGithubCreateRepositoryWebhookAction } from './githubCreateRepositoryWebhook';
import { createGithubWebhookAction } from './githubWebhook';
import { ScmIntegrations } from '@backstage/integration';
import { ConfigReader } from '@backstage/config';
import { getVoidLogger } from '@backstage/backend-common';
@@ -33,7 +33,7 @@ describe('github:repository:webhook:create', () => {
});
const integrations = ScmIntegrations.fromConfig(config);
const action = createGithubCreateRepositoryWebhookAction({ integrations });
const action = createGithubWebhookAction({ integrations });
const mockContext = {
input: {
@@ -24,7 +24,7 @@ import { createTemplateAction } from '../../createTemplateAction';
type ContentType = 'form' | 'json';
export function createGithubCreateRepositoryWebhookAction(options: {
export function createGithubWebhookAction(options: {
integrations: ScmIntegrationRegistry;
}) {
const { integrations } = options;
@@ -45,7 +45,7 @@ export function createGithubCreateRepositoryWebhookAction(options: {
contentType?: ContentType;
insecureSsl?: boolean;
}>({
id: 'github:repository:webhook:create',
id: 'github:webhook',
description: 'Creates webhook for a repository on GitHub.',
schema: {
input: {
@@ -15,4 +15,4 @@
*/
export { createGithubActionsDispatchAction } from './githubActionsDispatch';
export { createGithubCreateRepositoryWebhookAction } from './githubCreateRepositoryWebhook';
export { createGithubWebhookAction } from './githubWebhook';