Skip to content

Update documentation.yaml #8

Update documentation.yaml

Update documentation.yaml #8

# Action to deploy the mkdocs documentation to the branch gh-pages.
name: On Push Deploy Documentation # Name of the workflow
on:
push:
branches:
- main
paths:
- 'docs/**'
- 'overrides/**'
- '.github/workflows/**'
- 'mkdocs.yaml'
pull_request:
branches:
- main
paths:
- 'docs/**'
- 'overrides/**'
- '.github/workflows/**'
- 'mkdocs.yaml'
# Jobs
jobs: # Jobs to run
deploy: # Name of the job
name: deploy-documentation
runs-on: ubuntu-latest # Operating system to run the job on
steps: # Steps to run
- name: Checkout repo # Name of the step
uses: actions/checkout@v2 # Action to run
- name: Set up Python # Name of the step
uses: actions/setup-python@v2 # Action to run
with: # Inputs for the action
python-version: 3.7.13 # Version of Python to use
- name: Caching # Name of the step
uses: actions/cache@v2 # Action to run
with: # Inputs for the action
path: $/{/{ env.pythonLocation /}/} # Path to cache
key: $/{/{ env.pythonLocation /}/}-$/{/{ hashFiles('setup.py') /}/}-$/{/{ hashFiles('requirements.txt') /}/} # Key to use for restoring and saving the cache
- name: Install dependencies # Name of the step
run: | # Command to run
python -m pip install --upgrade pip
ls
pip install -r requirements
- name: Deploy documentation # Name of the step
run: python -m mkdocs gh-deploy --clean --force --verbose # Command to run