Skip to content

Commit 28755fe

Browse files
committed
feat(policy): add file_not_deleted predicate to workflow rules
1 parent 9236b18 commit 28755fe

File tree

1 file changed

+45
-0
lines changed

1 file changed

+45
-0
lines changed

.policy.dev.yml

+45
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
# This file is generated by policy-gen.
2+
# Do not edit directly. Run "make .policy.yml" to update.
3+
4+
policy:
5+
approval:
6+
- or:
7+
- and:
8+
- Workflow .github/workflows/build.yml succeeded or skipped
9+
- Workflow .github/workflows/lint.yml succeeded or skipped
10+
- default to approval
11+
approval_rules:
12+
- name: Workflow .github/workflows/build.yml succeeded or skipped
13+
if:
14+
changed_files:
15+
paths:
16+
- ^go\.mod$
17+
- ^go\.sum$
18+
- ^(?:(?:[^/]*(?:/|$))*)(?:[^/]*)\.go$
19+
- ^Dockerfile$
20+
- ^\.github\/workflows\/build\.yml$
21+
file_not_deleted:
22+
paths:
23+
- ^\.github\/workflows\/build\.yml$
24+
requires:
25+
conditions:
26+
has_workflow_result:
27+
conclusions:
28+
- skipped
29+
- success
30+
workflows:
31+
- .github/workflows/build.yml
32+
- name: Workflow .github/workflows/lint.yml succeeded or skipped
33+
if:
34+
file_not_deleted:
35+
paths:
36+
- ^\.github\/workflows\/lint\.yml$
37+
requires:
38+
conditions:
39+
has_workflow_result:
40+
conclusions:
41+
- skipped
42+
- success
43+
workflows:
44+
- .github/workflows/lint.yml
45+
- name: default to approval

0 commit comments

Comments
 (0)