-
-
Notifications
You must be signed in to change notification settings - Fork 101
33 lines (31 loc) · 888 Bytes
/
pages.yml
File metadata and controls
33 lines (31 loc) · 888 Bytes
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
name: Pages
on:
push:
branches:
- main
pull_request:
branches:
- main
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-latest
container: ghcr.io/asahilinux/mkdocs-asahi
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: true
- name: Configure Git Credentials
run: |
git config --global user.name github-actions[bot]
git config --global user.email 41898282+github-actions[bot]@users.noreply.github.com
# This is needed for the deployment to work
git config --global --add safe.directory "$GITHUB_WORKSPACE"
- name: Build
if: github.event_name == 'pull_request'
run: mkdocs build
- name: Build and deploy to GitHub Pages
if: github.event_name != 'pull_request'
run: mkdocs gh-deploy --force