-
Notifications
You must be signed in to change notification settings - Fork 16
40 lines (32 loc) · 1.11 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
39
40
name: Auto Update
on:
schedule:
- cron: '*/20 * * * *'
jobs:
update:
name: Update Data
runs-on: ubuntu-latest
steps:
- name: Checkout Repo
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Update Sources
run: ./bin/update_sources.sh
- name: Commit Sources Data
run: |
if git diff --name-only data/*.csv data/france-*.json data/vaccines.json | grep . ; then
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git commit -m "update sources data" data/*.csv data/france-*.json data/vaccines.json
fi
- name: Build Viz Data
run: ./bin/export-main-countries.py
- name: Commit & Push Viz Data
run: |
if git diff data/coronavirus-countries.json | grep . > /dev/null ; then
git config --local user.email "[email protected]"
git config --local user.name "GitHub Action"
git commit -m "update viz data" data/coronavirus-countries.json
git push
fi