1
1
mirror of https://github.com/wez/wezterm.git synced 2024-12-22 21:01:36 +03:00

ci: switch mkdocs build to docker version

ubuntu's pip stuff is preventing me from doing a basic user
install and I've had trouble in the past with the svg related deps.

Let's just switch to using a docker based version of mkdocs.
This commit is contained in:
Wez Furlong 2024-02-03 08:05:03 -07:00
parent 99c17b166f
commit 7d84bf5b44
No known key found for this signature in database
GPG Key ID: 7A7F66A31EC9B387
3 changed files with 7 additions and 9 deletions

1
.dockerignore Normal file
View File

@ -0,0 +1 @@
target

2
ci/Dockerfile.docs Normal file
View File

@ -0,0 +1,2 @@
FROM squidfunk/mkdocs-material
RUN pip install mkdocs-macros-plugin mkdocs-include-markdown-plugin mkdocs-exclude

View File

@ -41,13 +41,6 @@ python3 ci/generate-docs.py || exit 1
# Adjust path to pick up pip-installed binaries
PATH="$HOME/.local/bin;$PATH"
PIP=pip3
if ! hash pip3 >/dev/null ; then
PIP=pip
fi
$PIP install --quiet mkdocs-material mkdocs-git-revision-date-localized-plugin black mkdocs-exclude mkdocs-include-markdown-plugin mkdocs-macros-plugin pillow cairosvg
black ci/generate-docs.py ci/subst-release-info.py
cp "assets/icon/terminal.png" docs/favicon.png
@ -55,8 +48,10 @@ cp "assets/icon/wezterm-icon.svg" docs/favicon.svg
mkdir -p docs/fonts
cp assets/fonts/SymbolsNerdFontMono-Regular.ttf docs/fonts/
docker build -t wezterm/mkdocs-material -f ci/Dockerfile.docs .
if [ "$SERVE" == "yes" ] ; then
mkdocs "$@"
docker run --rm -it --network=host -v ${PWD}:/docs wezterm/mkdocs-material serve
else
mkdocs build
docker run --rm -e CARDS=true -v ${PWD}:/docs wezterm/mkdocs-material build
fi