generated from latex4ei/CheatsheetTemplate
-
Notifications
You must be signed in to change notification settings - Fork 0
38 lines (30 loc) · 1.13 KB
/
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
name: Update README and LaTeX Build File
on:
workflow_dispatch:
jobs:
update-and-create-pr:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.12.2'
- name: Run update script
run: python scripts/update_files.py
- name: Configure Git
run: |
git config user.name "github-actions[bot]"
git config user.email "41898282+github-actions[bot]@users.noreply.github.com"
- name: Commit changes to a new branch
run: |
git checkout -b changes/${{ github.run_id }}
git add .
git commit -m "Apply automated updates"
git push -u origin changes/${{ github.run_id }}
- name: Create Pull Request
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh pr create --base main --head changes/${{ github.run_id }} --title "Specify project URLs and CMake project" --body "Please review the changes applied by the automated script."