MtF-wiki/.github/workflows/test-build.yml

32 lines
749 B
YAML
Raw Normal View History

name: Test Site
on:
pull_request:
paths-ignore:
2021-12-24 10:23:22 +08:00
- '.github'
- 'README.md'
- 'LICENSE'
jobs:
build-deploy:
2021-11-28 08:45:19 +08:00
runs-on: ubuntu-20.04
if: "! contains(toJSON(github.event.commits.*.message), '[skip ci]')"
steps:
2021-11-28 08:45:19 +08:00
- uses: actions/checkout@v2
with:
submodules: true
2021-11-28 08:45:19 +08:00
fetch-depth: 0
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
2021-11-28 08:45:19 +08:00
hugo-version: latest
extended: true
2021-11-28 08:45:19 +08:00
- name: Hugo Cache
uses: actions/cache@v2
with:
2020-10-30 23:52:48 +08:00
path: /tmp/hugo_cache
key: ${{ runner.os }}-hugomod-${{ hashFiles('**/go.sum') }}
2021-11-28 08:45:19 +08:00
restore-keys: ${{ runner.os }}-hugomod-
- name: Build
2021-11-28 08:45:19 +08:00
run: hugo --minify