fix #18
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy docs | |
on: [push, pull_request] | |
jobs: | |
build: | |
name: Deploy docs | |
runs-on: ubuntu-latest | |
steps: | |
- name: Download source | |
uses: actions/checkout@v2 | |
- name: Install Crystal | |
uses: oprypin/install-crystal@v1 | |
- name: Install Python | |
uses: actions/setup-python@v2 | |
- name: Install Python libs | |
run: pip install --no-deps -r docs/requirements.txt | |
- name: Install Crystal libs | |
run: shards install --ignore-crystal-version | |
- name: Build site | |
run: mkdocs build | |
- name: Fix CNAME | |
run: echo docs.celestine.dev > docs/CNAME | |
- name: Deploy to gh-pages | |
if: github.event_name == 'push' && github.ref == 'refs/heads/main' | |
run: mkdocs gh-deploy --force |