Merge pull request #89 from bmeviauac01/hf2024webapi #218
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build docs | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build-docs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
# HOTFIX for https://github.com/actions/runner/issues/2033 | |
- name: Fix git safe.directory in container | |
run: mkdir -p /home/runner/work/_temp/_github_home && printf "[safe]\n\tdirectory = /github/workspace" > /home/runner/work/_temp/_github_home/.gitconfig | |
- name: Build HU docs | |
uses: ./ | |
env: | |
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | |
IsRevisionDatePluginEnabled: "true" | |
IsAuthorsPluginEnabled: "true" | |
with: | |
entrypoint: mkdocs | |
args: build --config-file=mkdocs.hu.yml | |
- name: Build EN docs | |
uses: ./ | |
env: | |
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" | |
IsRevisionDatePluginEnabled: "true" | |
IsAuthorsPluginEnabled: "true" | |
with: | |
entrypoint: mkdocs | |
args: build --config-file=mkdocs.en.yml | |
- name: Copy redirect index page | |
run: sudo cp ./index.html ./site | |
- name: Deploy docs to gh-pages branch | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_dir: ./site | |