-
Notifications
You must be signed in to change notification settings - Fork 253
40 lines (33 loc) · 1.01 KB
/
ci.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: cartola-data
on:
workflow_dispatch:
schedule:
- cron: "0 13 * * *"
jobs:
update-data:
runs-on: ubuntu-latest
steps:
- name: check out source code
uses: actions/checkout@master
with:
persist-credentials: false
fetch-depth: 0
- name: setup python
uses: actions/setup-python@v4
with:
python-version: '3.10.5'
cache: 'pip'
- name: install dependencies
run: pip install -r .github/workflows/requirements.txt
- name: download data
run: python src/cartola/download_data.py
- name: commit files
run: |
git config --local user.email "[email protected]"
git config --local user.name "Arnaldo Gualberto"
git add -f data/01_raw/
git diff --quiet && git diff --staged --quiet || git commit -am 'update cartola data'
- name: push
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}