Skip to content

Commit cc9d5fb

Browse files
committed
add workflow to gather approvals on release branch
1 parent 5b82931 commit cc9d5fb

2 files changed

Lines changed: 507 additions & 0 deletions

File tree

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
# *******************************************************************************
2+
# Copyright (c) 2026 Contributors to the Eclipse Foundation
3+
#
4+
# See the NOTICE file(s) distributed with this work for additional
5+
# information regarding copyright ownership.
6+
#
7+
# This program and the accompanying materials are made available under the
8+
# terms of the Apache License Version 2.0 which is available at
9+
# https://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# SPDX-License-Identifier: Apache-2.0
12+
# *******************************************************************************
13+
name: Check Release Branch Approvals
14+
on:
15+
pull_request_review:
16+
types: [submitted, edited, dismissed]
17+
jobs:
18+
check-approvals:
19+
name: Verify Required Approvals
20+
if: startsWith(github.event.pull_request.base.ref, 'release/')
21+
runs-on: ubuntu-latest
22+
permissions:
23+
contents: read
24+
pull-requests: write
25+
steps:
26+
- name: Checkout code
27+
uses: actions/checkout@v4
28+
- name: Set up Python
29+
uses: actions/setup-python@v5
30+
with:
31+
python-version: '3.12'
32+
cache: 'pip'
33+
cache-dependency-path: 'scripts/tooling/requirements.txt'
34+
- name: Install dependencies
35+
run: |
36+
pip install -r scripts/tooling/requirements.txt
37+
- name: Check Release Approvals
38+
id: check-approvals
39+
env:
40+
REPO_OWNER: ${{ github.repository_owner }}
41+
REPO_NAME: ${{ github.event.repository.name }}
42+
PR_NUMBER: ${{ github.event.pull_request.number }}
43+
BASE_BRANCH: ${{ github.base_ref }}
44+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
45+
run: |
46+
python3 scripts/tooling/cli/release/check_release_approvals.py
47+
- name: Success
48+
if: steps.check-approvals.outputs.all-approved == 'true'
49+
run: |
50+
echo "✅ All modules have required approvals"
51+
echo "Approved modules: ${{ steps.check-approvals.outputs.approved-modules }}"

0 commit comments

Comments
 (0)