Handle bad characters in log files from AMS #118
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: Documentation build and deploy | |
on: | |
push: | |
branches: [ master ] | |
tags: ['*'] | |
pull_request: | |
branches: [ master ] | |
workflow_dispatch: | |
concurrency: | |
group: CI-docs-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
sphinx-build: | |
runs-on: ubuntu-latest | |
if: "!contains(github.event.head_commit.message, '[skip ci]')" | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Install mamba | |
uses: mamba-org/setup-micromamba@main | |
with: | |
environment-file: docs/environment.yml | |
- name: Build anypytools | |
shell: bash -l {0} | |
run: pip install . | |
- name: Build Documentation | |
shell: bash -l {0} | |
run: | | |
set -e | |
cd docs | |
make html-dev | |
cd .. | |
mkdir -p public/dev | |
cp -rT docs/_build/html public/dev | |
- name: Build last tagged version | |
if: github.ref == 'refs/heads/master' | |
shell: bash -l {0} | |
run: | | |
git checkout $(git describe --tags `git rev-list --tags --max-count=1`); | |
cd docs | |
make clean | |
make html | |
cd .. | |
cp -rT docs/_build/html public | |
- name: Deploy 🚀 | |
if: github.ref == 'refs/heads/master' | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }} | |
external_repository: AnyBody-Research-Group/anypytools-docs | |
publish_branch: gh-pages | |
publish_dir: ./public |