-
-
Notifications
You must be signed in to change notification settings - Fork 1
49 lines (43 loc) · 1.42 KB
/
update-feeds.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
44
45
46
47
48
49
# This workflow scrapes the latest show episodes and commits the new episode and data
# files to the repo.
name: ⚒️ Scrape and commit
on:
schedule:
- cron: '0 0,12 * * *' # At midnight & noon UTC
workflow_dispatch: # Allows you to run this workflow manually from the Actions tab
jobs:
scrape:
runs-on: ubuntu-latest
permissions:
# Give the default GITHUB_TOKEN write permission to commit and push the
# added or changed files to the repository.
contents: write
if: github.repository_owner == 'qgis' || github.repository_owner == 'Xpirix'
steps:
- name: '🛒 Checkout QGIS Planet Website'
uses: actions/checkout@v4
with:
ref: main
path: ./qgis-planet-website
- name: '🐍 Setup Python'
uses: actions/setup-python@v5
with:
python-version: '3.13'
cache: 'pip'
cache-dependency-path: '**/REQUIREMENTS.txt'
- name: '🚸Install Python deps'
run: |
cd ./qgis-planet-website
pip install -r REQUIREMENTS.txt
pip freeze
- name: '🗞️ Fetch Feed Content'
run: |
cd ./qgis-planet-website
pip freeze
./fetch_feeds.py
- name: '✉️ Commit'
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: 'Posts scraped and committed via a GitHub Action.'
repository: ./qgis-planet-website
# push_options: --force