Skip to content

Commit 1663c73

Browse files
authored
tekton on-cel-expression (#439)
* tekton on-cel-expression * add missing paths
1 parent ed4b622 commit 1663c73

File tree

2 files changed

+36
-4
lines changed

2 files changed

+36
-4
lines changed

.tekton/network-observability-cli-ystream-pull-request.yaml

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,23 @@ metadata:
77
build.appstudio.redhat.com/pull_request_number: '{{pull_request_number}}'
88
build.appstudio.redhat.com/target_branch: '{{target_branch}}'
99
pipelinesascode.tekton.dev/max-keep-runs: "3"
10-
pipelinesascode.tekton.dev/on-cel-expression: event == "pull_request" && target_branch
11-
== "main"
10+
pipelinesascode.tekton.dev/on-cel-expression: |
11+
event == "pull_request" && target_branch == "main" && (
12+
".tekton/***".pathChanged() ||
13+
".dockerignore".pathChanged() ||
14+
"Dockerfile.downstream".pathChanged() ||
15+
"Dockerfile-args.downstream".pathChanged() ||
16+
"go.mod".pathChanged() ||
17+
"go.sum".pathChanged() ||
18+
"main.go".pathChanged() ||
19+
"Makefile".pathChanged() ||
20+
"cmd/***".pathChanged() ||
21+
"commands/***".pathChanged() ||
22+
"res/***".pathChanged() ||
23+
"scripts/***".pathChanged() ||
24+
".mk/***".pathChanged() ||
25+
"LICENSE".pathChanged()
26+
)
1227
creationTimestamp: null
1328
labels:
1429
appstudio.openshift.io/application: netobserv-ystream

.tekton/network-observability-cli-ystream-push.yaml

Lines changed: 19 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,25 @@ metadata:
77
build.appstudio.redhat.com/target_branch: '{{target_branch}}'
88
pipelinesascode.tekton.dev/max-keep-runs: "3"
99
# switch comment in/out at branch cut / release
10-
# pipelinesascode.tekton.dev/on-cel-expression: event == "push" && target_branch == "main"
11-
pipelinesascode.tekton.dev/on-cel-expression: "false"
10+
pipelinesascode.tekton.dev/on-cel-expression: |
11+
event == "push" && target_branch == "main" && (
12+
".tekton/***".pathChanged() ||
13+
".dockerignore".pathChanged() ||
14+
"Dockerfile.downstream".pathChanged() ||
15+
"Dockerfile-args.downstream".pathChanged() ||
16+
"go.mod".pathChanged() ||
17+
"go.sum".pathChanged() ||
18+
"main.go".pathChanged() ||
19+
"Makefile".pathChanged() ||
20+
"cmd/***".pathChanged() ||
21+
"commands/***".pathChanged() ||
22+
"res/***".pathChanged() ||
23+
"scripts/***".pathChanged() ||
24+
".mk/***".pathChanged() ||
25+
"LICENSE".pathChanged() ||
26+
"vendor/***".pathChanged()
27+
)
28+
# pipelinesascode.tekton.dev/on-cel-expression: "false"
1229
creationTimestamp: null
1330
labels:
1431
appstudio.openshift.io/application: netobserv-ystream

0 commit comments

Comments
 (0)