-
Notifications
You must be signed in to change notification settings - Fork 1
43 lines (40 loc) · 1.23 KB
/
Copy pathmeritindia-current.yml
File metadata and controls
43 lines (40 loc) · 1.23 KB
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: meritindia-current-generation
on:
workflow_dispatch: {}
schedule:
# randomly chosen minute, every hour
- cron: '12 * * * *'
jobs:
get-current-generation:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Check out this repo
uses: actions/checkout@v4
- name: Fetch latest india data
run: python3 current_generation.py india
working-directory: ./src/meritindia
env:
PROXY_URL: ${{ secrets.PROXY_URL }}
- name: Commit and push if it changed
run: |-
git config user.name "Automated"
git config user.email "actions@users.noreply.github.com"
git add -A
timestamp=$(date -u)
git commit -m "Latest india data: ${timestamp}" || exit 0
git push
- name: Fetch state data
run: python3 current_generation.py states
working-directory: ./src/meritindia
env:
PROXY_URL: ${{ secrets.PROXY_URL }}
- name: Commit and push if it changed
run: |-
git config user.name "Automated"
git config user.email "actions@users.noreply.github.com"
git add -A
timestamp=$(date -u)
git commit -m "Latest states data: ${timestamp}" || exit 0
git push