Add release event trigger (#3226)

Supersedes #764 

Bitbucket does not support release webhooks.

---------

Co-authored-by: Patrick Schratz <patrick.schratz@gmail.com>
This commit is contained in:
qwerty287
2024-01-30 17:39:00 +01:00
committed by GitHub
parent da4bd8b97d
commit 9df572ef31
35 changed files with 628 additions and 18 deletions

View File

@@ -267,7 +267,8 @@
"pr": "Pull Request",
"deploy": "Deploy",
"cron": "Cron",
"manual": "Manual"
"manual": "Manual",
"release": "Release"
},
"status": {
"status": "Status: {status}",

View File

@@ -40,7 +40,7 @@
<Icon v-if="pipeline.event === 'pull_request'" name="pull-request" />
<Icon v-else-if="pipeline.event === 'pull_request_closed'" name="pull-request-closed" />
<Icon v-else-if="pipeline.event === 'deployment'" name="deployment" />
<Icon v-else-if="pipeline.event === 'tag'" name="tag" />
<Icon v-else-if="pipeline.event === 'tag' || pipeline.event === 'release'" name="tag" />
<Icon v-else-if="pipeline.event === 'cron'" name="push" />
<Icon v-else-if="pipeline.event === 'manual'" name="manual-pipeline" />
<Icon v-else name="push" />

View File

@@ -29,7 +29,7 @@
<span class="truncate">{{ prettyRef }}</span>
</router-link>
<div v-else class="flex space-x-1 items-center min-w-0">
<Icon v-if="pipeline.event === 'tag'" name="tag" />
<Icon v-if="pipeline.event === 'tag' || pipeline.event === 'release'" name="tag" />
<span class="truncate">{{ prettyRef }}</span>
</div>

View File

@@ -102,6 +102,7 @@ function removeImage(image: string) {
const secretEventsOptions: CheckboxOption[] = [
{ value: WebhookEvents.Push, text: i18n.t('repo.pipeline.event.push') },
{ value: WebhookEvents.Tag, text: i18n.t('repo.pipeline.event.tag') },
{ value: WebhookEvents.Release, text: i18n.t('repo.pipeline.event.release') },
{
value: WebhookEvents.PullRequest,
text: i18n.t('repo.pipeline.event.pr'),

View File

@@ -1,6 +1,7 @@
export enum WebhookEvents {
Push = 'push',
Tag = 'tag',
Release = 'release',
PullRequest = 'pull_request',
PullRequestClosed = 'pull_request_closed',
Deploy = 'deployment',