From e883d43d77bc61b8bc84fdb652aa9d0a3b25fb8e Mon Sep 17 00:00:00 2001 From: Marcus Noble Date: Wed, 3 Jun 2020 19:33:57 +0100 Subject: [PATCH] Fixed split function in Tekton bindings --- tekton/eventlisteners/webhook.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tekton/eventlisteners/webhook.yaml b/tekton/eventlisteners/webhook.yaml index ebda81b..ea0d01b 100644 --- a/tekton/eventlisteners/webhook.yaml +++ b/tekton/eventlisteners/webhook.yaml @@ -24,12 +24,12 @@ spec: - name: deploy-master interceptors: - cel: - filter: "header.match('X-GitHub-Event', 'push') && split(body.ref, '/')[2] == body.repository.default_branch" + filter: "header.match('X-GitHub-Event', 'push') && body.ref.split('/')[2] == body.repository.default_branch" overlays: - key: commit_sha expression: "body.after" - key: branch - expression: "split(body.ref, '/')[2]" + expression: "body.ref.split('/')[2]" - key: ref expression: "body.ref" - key: number