-
Notifications
You must be signed in to change notification settings - Fork 67
41 lines (35 loc) · 1.02 KB
/
release-update.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
38
39
40
41
name: Update release
on:
pull_request:
branches:
- 'main'
paths:
- 'CHANGELOG.md'
permissions:
contents: write
jobs:
run_if:
if: startsWith(github.head_ref, 'release/')
name: "Sync changelog"
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: "${{ github.event.inputs.branch }}"
fetch-depth: 0
- name: Setup python
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Install python dependencies
working-directory: .github/workflows/scripts/changelog
run: pip install -r requirements.txt
- name: Update release from changelog
working-directory: .github/workflows/scripts/changelog
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
run: |
python update_release.py \
--changelog-path="../../../../CHANGELOG.md" \
--root-repo-name=${{ github.repository_owner }}/${{ github.event.repository.name }}