-
Notifications
You must be signed in to change notification settings - Fork 1
49 lines (45 loc) · 1.29 KB
/
workflow-vcp.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
48
49
name: "VCP"
runs-on: self-hosted
on:
push:
branches:
- master
schedule:
- cron: "31 9 * * 1-5"
env:
TZ: Asia/Shanghai
jobs:
build:
runs-on: ubuntu-20.04
steps:
- name: Setup timezone
run: export TZ='Asia/Shanghai'
# - name: Setup timezone
# uses: zcong1993/setup-timezone@master
# with:
# timezone: Asia/Shanghai
# - name: "Setup python 3.x"
# uses: actions/setup-python@v2
# with:
# python-version: "3.9.0"
# - name: "Update pip3"
# run: /opt/hostedtoolcache/Python/3.9.0/x64/bin/python -m pip install --upgrade pip
- name: "Install dependencies"
run: python -m pip install pandas tushare matplotlib mplfinance
- name: "Checkout codes"
uses: actions/checkout@v2
- name: "Update VCP"
env:
PRO_KEY: ${{ secrets.PRO_KEY }}
run: python scripts/vcp.py
- name: "Commit"
run: |
git config --global user.name ${{ secrets.GIT_NAME }}
git config --global user.email ${{ secrets.GIT_EMAIL }}
git add .
git commit -m "update data" -a
- name: "Push changes"
uses: ad-m/github-push-action@master
with:
github_token: ${{ secrets.GIT_TK }}
force: true