-
Notifications
You must be signed in to change notification settings - Fork 1
47 lines (39 loc) · 1.77 KB
/
DLAndCommit.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
name: download and commit
on:
schedule:
- cron: '0 10 * * *' # 1日1回 UTCでの10時に
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
with:
ref: main
- name: Install dependencies
run: |
pip install pandas openpyxl
- name: Copy byouin_list
run: |
curl -o data/byouin_list/org/byouin_list.xlsx "https://www.city.kumamoto.jp/opendata/pub/byouin_list.xlsx"
python script/xls2csv.py data/byouin_list/org/byouin_list.xlsx
- name: Copy yakkyoku_list
run: |
curl -o data/yakkyoku_list/org/yakkyoku_list.xlsx "https://www.city.kumamoto.jp/opendata/pub/yakkyoku_list.xlsx"
python script/xls2csv.py data/yakkyoku_list/org/yakkyoku_list.xlsx
- name: Copy tennpohannbaigyou_list
run: |
curl -o data/tennpohannbaigyou_list/org/tennpohannbaigyou_list.xlsx "https://www.city.kumamoto.jp/opendata/pub/tennpohannbaigyou_list.xlsx"
python script/xls2csv.py data/tennpohannbaigyou_list/org/tennpohannbaigyou_list.xlsx
- name: Copy Insyokutenneigyoukyoka
run: curl -o data/Insyokutenneigyoukyoka/org/Insyokutenneigyoukyoka.csv "https://www.city.kumamoto.jp/opendata/pub/Insyokutenneigyoukyoka.csv"
- name: Commit files
run: |
git config --local user.useConfigOnly false
git config --local user.name "Scraping Bot"
git config --local user.email "[email protected]"
git status
# | grep modified
# && git add . && git commit -v -m "[Bot] GitHub Actions - get data at $(date +'%Y-%m-%d')"
# - name: Create Pull Request
# uses: peter-evans/create-pull-request@v3