mirror of
https://github.com/h44z/wg-portal
synced 2025-02-26 05:49:14 +00:00
docs: build multi-version documentation (#327)
* Build multi-version docs with 'mike' Signed-off-by: Dmytro Bondar <git@bonddim.com> * Revert remote_branch option --------- Signed-off-by: Dmytro Bondar <git@bonddim.com>
This commit is contained in:
parent
afcba8d43e
commit
ba9b6c39e0
25
.github/workflows/pages.yml
vendored
25
.github/workflows/pages.yml
vendored
@ -1,22 +1,29 @@
|
|||||||
name: github-pages
|
name: github-pages
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches: [master]
|
||||||
- master
|
tags: ["v*"]
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
contents: write
|
contents: write
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
deploy:
|
deploy:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
- uses: actions/setup-python@v5
|
- uses: actions/setup-python@v5
|
||||||
with:
|
with:
|
||||||
python-version: 3.x
|
python-version: 3.x
|
||||||
- uses: actions/cache@v4
|
|
||||||
with:
|
- name: Install dependencies
|
||||||
key: ${{ github.ref }}
|
run: pip install mike mkdocs-material[imaging] mkdocs-minify-plugin
|
||||||
path: .cache
|
|
||||||
- run: pip install mkdocs-material
|
- name: Publish documentation
|
||||||
- run: pip install pillow cairosvg
|
run: mike deploy --push --update-aliases ${{ github.ref_name }} latest
|
||||||
- run: mkdocs gh-deploy --force
|
env:
|
||||||
|
GIT_COMMITTER_NAME: "github-actions[bot]"
|
||||||
|
GIT_COMMITTER_EMAIL: "41898282+github-actions[bot]@users.noreply.github.com"
|
||||||
|
@ -327,7 +327,7 @@
|
|||||||
<div class="md-container">
|
<div class="md-container">
|
||||||
<div class="tx-hero__image">
|
<div class="tx-hero__image">
|
||||||
<img
|
<img
|
||||||
src="{{config.site_url}}assets/images/screenshot.png"
|
src="{{config.site_url}}/assets/images/screenshot.png"
|
||||||
alt=""
|
alt=""
|
||||||
draggable="false"
|
draggable="false"
|
||||||
>
|
>
|
||||||
@ -356,7 +356,7 @@
|
|||||||
<div class="second-column">
|
<div class="second-column">
|
||||||
<div class="image-wrapper">
|
<div class="image-wrapper">
|
||||||
<img
|
<img
|
||||||
src="{{config.site_url}}assets/images/wg-tool.png"
|
src="{{config.site_url}}/assets/images/wg-tool.png"
|
||||||
alt=""
|
alt=""
|
||||||
draggable="false"
|
draggable="false"
|
||||||
>
|
>
|
||||||
|
25
mkdocs.yml
25
mkdocs.yml
@ -1,13 +1,14 @@
|
|||||||
# build with MkDocs 1.5.3, mkdocs-material-9.4.7
|
---
|
||||||
|
|
||||||
site_name: WireGuard Portal
|
site_name: WireGuard Portal
|
||||||
site_description: 'Manage WireGuard Peers and Interface using a beautiful and simple web UI.'
|
site_description: Manage WireGuard Peers and Interface using a beautiful and simple web UI.
|
||||||
site_url: https://wgportal.org
|
site_url: https://wgportal.org/
|
||||||
repo_name: 'h44z/wg-portal'
|
repo_name: h44z/wg-portal
|
||||||
repo_url: 'https://github.com/h44z/wg-portal'
|
repo_url: https://github.com/h44z/wg-portal
|
||||||
copyright: 'Copyright © 2023-2024 WireGuard Portal Project'
|
copyright: Copyright © 2023-2024 WireGuard Portal Project
|
||||||
|
|
||||||
extra_css:
|
extra_css:
|
||||||
- stylesheets/extra.css
|
- stylesheets/extra.css
|
||||||
|
|
||||||
theme:
|
theme:
|
||||||
name: material
|
name: material
|
||||||
custom_dir: docs/theme-overrides
|
custom_dir: docs/theme-overrides
|
||||||
@ -18,15 +19,19 @@ theme:
|
|||||||
favicon: assets/images/favicon-large.png
|
favicon: assets/images/favicon-large.png
|
||||||
language: en
|
language: en
|
||||||
features:
|
features:
|
||||||
- tabs
|
- navigation.instant
|
||||||
- instant
|
|
||||||
- navigation.tabs
|
- navigation.tabs
|
||||||
|
|
||||||
plugins:
|
plugins:
|
||||||
- search
|
- search
|
||||||
#- social # disable until https://github.com/squidfunk/mkdocs-material/issues/6983 is resolved
|
- social
|
||||||
|
- minify:
|
||||||
|
minify_html: true
|
||||||
|
|
||||||
extra:
|
extra:
|
||||||
|
version:
|
||||||
|
provider: mike
|
||||||
|
default: latest
|
||||||
social:
|
social:
|
||||||
- icon: fontawesome/brands/github-alt
|
- icon: fontawesome/brands/github-alt
|
||||||
link: https://github.com/h44z/wg-portal
|
link: https://github.com/h44z/wg-portal
|
||||||
|
Loading…
Reference in New Issue
Block a user