Skip to content

Commit 4fc3e3f

Browse files
authored
Enable branch protection (#191)
This change enables the same branch protection that was implemented in `logging-log4j2`. See apache/logging-log4j2#3582 and apache/logging-log4j2#3662
1 parent 87264fd commit 4fc3e3f

File tree

1 file changed

+25
-2
lines changed

1 file changed

+25
-2
lines changed

.asf.yaml

Lines changed: 25 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,15 @@ github:
4545
features:
4646
issues: true
4747

48-
del_branch_on_merge: true
48+
# Pull Request settings:
49+
# https://github.com/apache/infrastructure-asfyaml#pull-request-settings
50+
pull_requests:
51+
# allow auto-merge
52+
allow_auto_merge: true
53+
# enable updating head branches of pull requests
54+
allow_update_branch: true
55+
# auto-delete head branches after being merged
56+
del_branch_on_merge: true
4957

5058
# Enforce squashing while merging PRs.
5159
# Otherwise, the git log gets polluted severely.
@@ -54,7 +62,22 @@ github:
5462
merge: false
5563
rebase: false
5664

57-
# Prevent force pushes to primary branches
65+
# Enforce Review-then-Commit
5866
protected_branches:
5967
main:
68+
# All commits must be signed
6069
required_signatures: true
70+
# All reviews must be addressed before merging
71+
required_conversation_resolution: true
72+
# Require checks to pass before merging
73+
required_status_checks:
74+
checks:
75+
# The GitHub Actions app: 15368
76+
- app_id: 15368
77+
context: "build / build (ubuntu-latest)"
78+
# The GitHub Advanced Security app: 57789
79+
- app_id: 57789
80+
context: "CodeQL"
81+
# At least one positive review must be present
82+
required_pull_request_reviews:
83+
required_approving_review_count: 1

0 commit comments

Comments
 (0)