2024-01-18 14:05:45 +01:00
|
|
|
name: Continuous Integration
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
2024-01-18 14:13:28 +01:00
|
|
|
runs-on: ubuntu-22.04
|
2024-01-18 14:05:45 +01:00
|
|
|
env:
|
|
|
|
CI_COMMIT_MESSAGE: Continuous Integration update docs
|
|
|
|
CI_COMMIT_AUTHOR: Continuous Integration
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
|
2024-01-18 14:16:06 +01:00
|
|
|
- run: apt update -y
|
|
|
|
- run: apt install python3-pip -y
|
2024-01-18 14:14:50 +01:00
|
|
|
- run: pip3 install mkdocs-material
|
2024-01-18 14:05:45 +01:00
|
|
|
|
|
|
|
- run: mkdocs build
|
|
|
|
|
|
|
|
# Commit and push all changed files.
|
|
|
|
- name: GIT Commit Build Artifacts (coverage, dist, devdist, docs)
|
|
|
|
run: |
|
|
|
|
git config --global user.name "${{ env.CI_COMMIT_AUTHOR }}"
|
|
|
|
git config --global user.email "username@users.noreply.github.com"
|
2024-01-18 14:46:27 +01:00
|
|
|
git subtree add --prefix=pages origin/pages --squash
|
|
|
|
git subtree pull --prefix=pages origin/pages
|
|
|
|
rm -rf pages/*
|
|
|
|
cp -r site/* pages/
|
2024-01-18 14:05:45 +01:00
|
|
|
git commit -m "${{ env.CI_COMMIT_MESSAGE }}"
|
2024-01-18 14:46:27 +01:00
|
|
|
git subtree push --prefix deploy origin pages
|