-
Notifications
You must be signed in to change notification settings - Fork 0
33 lines (33 loc) · 1.02 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: ci
on:
push:
branches:
- master
- main
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: 3.x
- uses: actions/cache@v2
with:
key: ${{ github.ref }}
path: .cache
- run: pip install mkdocs
- run: pip install mkdocs-material
- run: pip install pillow cairosvg
- run: pip install mkdocs-glightbox
- run: pip install mkdocs-material[imaging]
- run: sudo apt-get install imagemagick pngquant
- run: find . -name '*.png' -execdir bash -c 'mogrify -resize 750x "$1"' - {} \;
- run: find . -name '*.png' -execdir bash -c 'pngquant "$1" --ext .png --force' - {} \;
# Replace 2 spaces with 4 spaces in list items
- name: Replace two spaces with four before list items
run: |
find . -name '*.md' -exec sed -i 's/^ \*/ */' {} \;
- run: mkdocs gh-deploy --force