feat: workflow should work

This commit is contained in:
Pavel Korytov 2021-11-26 17:22:29 +03:00
parent 85fe3d21b9
commit c4f388af85
2 changed files with 39 additions and 0 deletions

36
.github/workflows/update.yml vendored Normal file
View file

@ -0,0 +1,36 @@
name: Build site
on:
repository_dispatch:
push:
branches:
- master
jobs:
deploy:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: 'latest'
extended: true
- name: Install dependencies
run:
- sudo apt install emacs-nox python3 python3-pip
- pip3 install -r ./scripts/requirements.txt
- name: Run scripts
run:
- bash ./scripts/dot-stats-get-lengths.sh
- python3 ./scripts/dot-stats-plot-history.py
- python3 ./scripts/dot-stats-plot-lengths.py
- name: Build
run: hugo
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
if: github.ref == 'refs/heads/master'
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./public

3
scripts/requirements.txt Normal file
View file

@ -0,0 +1,3 @@
matplotlib
pandas
numpy