-
-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (40 loc) · 1.18 KB
/
updateFeedToday.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
42
43
name: 🔂 RunParsersToday
on:
workflow_dispatch:
schedule:
- cron: "32 7-11 * * 1-5" # UTC
- cron: "35 5 * * 1" # UTC run earlier on monday
concurrency:
group: parsers-${{ github.ref }}
cancel-in-progress: true
jobs:
generateXMLFeedsToday:
runs-on: ubuntu-latest
timeout-minutes: 15
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Install requirements.txt
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: git config
run: |
git config --global user.name github-actions
git config --global user.email 41898282+github-actions[bot]@users.noreply.github.com
git pull --ff-only
- name: Run parsers & update xml feeds
run: |
python updateFeeds.py -today
- name: git commit & push
run: |
git add docs
# Use "|| true" or "--allow-empty" otherwise the action fails for empty commits
git commit -m "Updated xml feeds" || true
git push
- name: Test files in github pages
run: |
python tests/test_ghpages.py