Skip to content

Commit

Permalink
Add new const represent pullrequest title and true false (#464)
Browse files Browse the repository at this point in the history
Add pullrequest title const and true false

Signed-off-by: yuzhipeng <[email protected]>
  • Loading branch information
yuzp1996 authored Jul 11, 2023
1 parent b9e736b commit 8143952
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 13 deletions.
27 changes: 14 additions & 13 deletions apis/meta/v1alpha1/cloudevent.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,19 +100,20 @@ func (evt *CloudEvent) GetValWithKey(ctx context.Context, path *field.Path) (val
}

const (
CloudEventPrefix = "dev.katanomi.cloudevents"
CloudEventExtGitReference = "reference"
CloudEventExtGitBranch = "branch"
CloudEventExtGitCommitMessage = "commitmessage"
CloudEventExtGitCommitID = "commit"
CloudEventExtGitSourceBranch = "sourcebranch"
CloudEventExtGitTargetBranch = "targetbranch"
CloudEventExtGitTag = "tag"
CloudEventExtAction = "action"
CloudEventExtSender = "sender"
CloudEventExtPullRequestNumber = "number"
CloudEventExtCodeRepository = "repository"
CloudEventExtWebhookType = "webhooktype"
CloudEventPrefix = "dev.katanomi.cloudevents"
CloudEventExtGitReference = "reference"
CloudEventExtGitBranch = "branch"
CloudEventExtGitCommitMessage = "commitmessage"
CloudEventExtGitPullRequestTitle = "pullrequesttitle"
CloudEventExtGitCommitID = "commit"
CloudEventExtGitSourceBranch = "sourcebranch"
CloudEventExtGitTargetBranch = "targetbranch"
CloudEventExtGitTag = "tag"
CloudEventExtAction = "action"
CloudEventExtSender = "sender"
CloudEventExtPullRequestNumber = "number"
CloudEventExtCodeRepository = "repository"
CloudEventExtWebhookType = "webhooktype"
// CloudEventExtRevisionSubmitter indicates email of revision submitter
CloudEventExtRevisionSubmitter = "revisionsubmitter"

Expand Down
7 changes: 7 additions & 0 deletions apis/meta/v1alpha1/labels_annotations.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,3 +170,10 @@ const (
// UserOwnedAnnotationKey annotated the resource's owner is one user
UserOwnedAnnotationKey = "katanomi.dev/owned.username" // NOSONAR // ignore: "Key" detected here, make sure this is not a hard-coded credential
)

const (
// TrueValue represent string true
TrueValue = "true"
// FalseValue represent string false
FalseValue = "false"
)

0 comments on commit 8143952

Please sign in to comment.