-
Notifications
You must be signed in to change notification settings - Fork 2
33 lines (31 loc) · 872 Bytes
/
cron.yaml
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
name: AAA-SA-gas-prices
on:
push:
branches:
- main
schedule:
- cron: "0 */6 * * *"
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: 🍽️ Get working copy
uses: actions/checkout@master
with:
fetch-depth: 1
- name: 🐍 Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: "3.8"
- name: 💿 Install Requirements
run: pip install -r requirements.txt
- name: 🍳 Update dataset
run: python3 app.py
- name: 🚀 Commit and push if it changed
run: |
git config user.name "${GITHUB_ACTOR}"
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
git add -A
timestamp=$(date -u)
git commit -m "Latest data: ${timestamp}" || exit 0
git push