forked from TechEmpower/FrameworkBenchmarks
-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (37 loc) · 1.21 KB
/
get-maintainers.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
name: get-maintainers
on:
pull_request:
types: [opened, reopened]
permissions:
pull-requests: write
jobs:
get_maintainers:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 10
- name: Get commit branch and commit message from PR
run: |
echo "BRANCH_NAME=$GITHUB_HEAD_REF" >> $GITHUB_ENV
echo "TARGET_BRANCH_NAME=$(echo ${GITHUB_BASE_REF##*/})" >> $GITHUB_ENV
echo "COMMIT_MESSAGE<<EOF" >> $GITHUB_ENV
echo "$(git log --format=%B -n 1 HEAD^2)" >> $GITHUB_ENV
echo "EOF" >> $GITHUB_ENV
echo "PREVIOUS_COMMIT=$(git log --format=%H -n 1 HEAD^2~1)" >> $GITHUB_ENV
- uses: actions/setup-python@v5
with:
python-version: '3.10'
architecture: 'x64'
- name: Save PR number
run: |
mkdir -p ./maintainers
echo ${{ github.event.number }} > ./maintainers/NR
- name: Get Maintainers
run: |
python ./toolset/github_actions/get_maintainers.py > ./maintainers/maintainers.md
- name: Save Maintainers
uses: actions/upload-artifact@v4
with:
name: maintainers
path: maintainers/