2024-01-18 14:05:45 +01:00
|
|
|
name: Continuous Integration
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- main
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
build:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
env:
|
|
|
|
CI_COMMIT_MESSAGE: Continuous Integration update docs
|
|
|
|
CI_COMMIT_AUTHOR: Continuous Integration
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v3
|
|
|
|
|
|
|
|
- uses: actions/setup-python@v4
|
2024-01-18 14:07:08 +01:00
|
|
|
with:
|
|
|
|
python-version: 3.x
|
2024-01-18 14:05:45 +01:00
|
|
|
- run: pip install mkdocs-material
|
|
|
|
|
|
|
|
- run: mkdocs build
|
|
|
|
|
|
|
|
# Commit and push all changed files.
|
2024-01-18 15:13:21 +01:00
|
|
|
- run: |
|
2024-01-18 14:05:45 +01:00
|
|
|
git config --global user.name "${{ env.CI_COMMIT_AUTHOR }}"
|
|
|
|
git config --global user.email "username@users.noreply.github.com"
|
2024-01-18 15:13:21 +01:00
|
|
|
- run: |
|
|
|
|
mkdir pages
|
|
|
|
cp -r site/* pages/
|
|
|
|
- run: |
|
|
|
|
git add pages/
|
2024-01-18 14:05:45 +01:00
|
|
|
git commit -m "${{ env.CI_COMMIT_MESSAGE }}"
|
2024-01-18 15:13:21 +01:00
|
|
|
git pull
|
|
|
|
- run: git subtree push --prefix pages origin gitea-pages
|