From 5569c84c0f5398682fa48724a220288ed53d5625 Mon Sep 17 00:00:00 2001 From: Pavel Sturc Date: Fri, 19 Apr 2024 13:53:52 +0200 Subject: [PATCH] feat: skip CI when the PR is in draft --- .tekton/pull-request.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.tekton/pull-request.yaml b/.tekton/pull-request.yaml index 478773e2e0..e76a7f5b47 100644 --- a/.tekton/pull-request.yaml +++ b/.tekton/pull-request.yaml @@ -4,7 +4,7 @@ kind: PipelineRun metadata: name: build-definitions-pull-request annotations: - pipelinesascode.tekton.dev/on-cel-expression: (event == "pull_request" && target_branch == "main") || (event == "push" && target_branch.startsWith("gh-readonly-queue/main/")) + pipelinesascode.tekton.dev/on-cel-expression: (event == "pull_request" && target_branch == "main" && body.pull_request.draft == false) || (event == "push" && target_branch.startsWith("gh-readonly-queue/main/")) pipelinesascode.tekton.dev/task: "[task/git-clone/0.1/git-clone.yaml, .tekton/tasks/buildah.yaml, .tekton/tasks/yaml-lint.yaml, .tekton/tasks/e2e-test.yaml, task/sast-snyk-check/0.1/sast-snyk-check.yaml]" pipelinesascode.tekton.dev/task-2: "yaml-lint" pipelinesascode.tekton.dev/max-keep-runs: "5"