forked from ctf-wiki/ctf-wiki
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbuild.sh
More file actions
executable file
·23 lines (18 loc) · 793 Bytes
/
Copy pathbuild.sh
File metadata and controls
executable file
·23 lines (18 loc) · 793 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#!/usr/bin/env bash
# Push HTML files to gh-pages automatically.
# Fill this out with the correct org/repo
ORG=ctf-wiki
REPO=ctf-wiki
# This probably should match an email for one of your users.
EMAIL=git@40huo.cn
set -e
# Clone Theme for Editing
if [ ! -d "mkdocs-material" ] ; then
git clone --depth 1 https://github.com/squidfunk/mkdocs-material.git
fi
sed -i "s/name: 'material'/name: null\n custom_dir: 'mkdocs-material\/material'\n static_templates:\n - 404.html/g" mkdocs.yml
# Change Google CDN to loli.net
sed -i 's/fonts.gstatic.com/gstatic.loli.net/g' mkdocs-material/material/base.html
sed -i 's/fonts.googleapis.com/fonts.loli.net/g' mkdocs-material/material/base.html
cp ./static/gitalk.html mkdocs-material/material/partials/integrations/disqus.html
mkdocs build -v