Repository navigation
62 lines (51 loc) · 1.69 KB
/
Copy pathmkdocs.yml
File metadata and controls
62 lines (51 loc) · 1.69 KB
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: mkdocs
on:
push:
branches:
- main
workflow_dispatch:
# Default to bash in login mode; key to activating conda environment
# https://github.com/mamba-org/provision-with-micromamba#IMPORTANT
defaults:
run:
shell: "bash -l {0}"
# Deny all permissions by default
permissions: {}
env:
MICROMAMBA_VERSION: 'latest'
concurrency:
group: ci-${{ github.ref }}
cancel-in-progress: true
jobs:
build:
name: Deploy docs
runs-on: ubuntu-latest
permissions:
contents: write # for mkdocs gh-deploy to push to gh-pages branch
steps:
- uses: actions/checkout@d23441a48e516b6c34aea4fa41551a30e30af803 # v6.1.0
with:
submodules: "recursive"
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
persist-credentials: true
- name: Configure Git Credentials
run: |
git config user.name github-actions[bot]
git config user.email 41898282+github-actions[bot]@users.noreply.github.com
- name: Install dependencies
uses: mamba-org/setup-micromamba@add3a49764cedee8ee24e82dfde87f5bc2914462 # v2.0.7
with:
micromamba-version: "${{ env.MICROMAMBA_VERSION }}"
environment-file: "environments/dev-environment.yaml"
cache-environment: true
- name: Install conda-lock
run: "pip install ."
- run: echo "cache_id=$(date --utc '+%V')" >> $GITHUB_ENV
- uses: actions/cache@caa296126883cff596d87d8935842f9db880ef25 # v5.1.0
with:
key: mkdocs-material-${{ env.cache_id }}
path: .cache
restore-keys: |
mkdocs-material-
- name: Deploy with mkdocs
run: mkdocs gh-deploy --force