Skip to content

Commit ddf4320

Browse files
committed
some ci/cd stuff idk
1 parent a16feea commit ddf4320

1 file changed

Lines changed: 35 additions & 0 deletions

File tree

.github/workflows/updater.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: Python script to update documentations and header details on merge
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
run-script:
10+
runs-on: ubuntu-latest
11+
12+
steps:
13+
- name: Checkout repository
14+
uses: actions/checkout@v4
15+
16+
- name: Set up Python
17+
uses: actions/setup-python@v5
18+
with:
19+
python-version: '3.x'
20+
21+
- name: Install dependencies
22+
run: |
23+
pip install -r requirements.txt || true # skip if no file
24+
25+
- name: Run script
26+
run: python auxiliary/updater.py
27+
28+
- name: Commit and push changes
29+
if: success()
30+
run: |
31+
git config user.name "github-actions[bot]"
32+
git config user.email "github-actions[bot]@users.noreply.github.com"
33+
git add -A
34+
git diff-index --quiet HEAD || git commit -m "Automated update after merge"
35+
git push

0 commit comments

Comments
 (0)