-
Notifications
You must be signed in to change notification settings - Fork 17
41 lines (39 loc) · 1.08 KB
/
publish.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
name: Build & Deploy Docs Site (on-merge)
on:
push:
paths:
- 'docs/**'
branches:
- master
- dev
pull_request:
paths:
- 'docs/**'
types: [closed]
jobs:
docs:
if: github.event.pull_request.merged == true
runs-on: ubuntu-18.04
steps:
- uses: actions/checkout@master
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@master
with:
python-version: 3.7
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt
- name: Build starter-pack Docs
working-directory: './'
run: |
mkdocs build --theme material \
--site-dir ../site/
- name: Deploy to GitHub Pages
uses: peaceiris/[email protected]
with:
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }}
publish_dir: ./site
allow_empty_commit: true