2020-02-16 15:31:06 +01:00
|
|
|
version: 2.1
|
2020-02-16 15:25:47 +01:00
|
|
|
jobs:
|
|
|
|
build-check:
|
|
|
|
parameters:
|
|
|
|
example-site-path:
|
|
|
|
type: string
|
|
|
|
theme-path:
|
|
|
|
type: string
|
|
|
|
docker:
|
2020-02-18 09:22:24 +01:00
|
|
|
- image: cibuilds/hugo:0.62
|
2020-02-16 15:25:47 +01:00
|
|
|
working_directory: ~/LoveIt
|
|
|
|
steps:
|
|
|
|
- checkout
|
|
|
|
- run: git submodule sync
|
|
|
|
- run: git submodule update --init
|
|
|
|
- run:
|
2020-02-16 15:35:31 +01:00
|
|
|
command: |
|
2020-02-18 09:22:24 +01:00
|
|
|
cd << parameters.example-site-path >> && pwd
|
|
|
|
HUGO_ENV=production hugo --themesDir << parameters.theme-path >> -v --gc
|
|
|
|
htmlproofer public --check-html --allow-hash-href --empty-alt-ignore --disable-external
|
2020-02-16 15:25:47 +01:00
|
|
|
workflows:
|
|
|
|
build-check-exampleSite:
|
|
|
|
jobs:
|
|
|
|
- build-check:
|
|
|
|
example-site-path: exampleSite
|
|
|
|
theme-path: ../..
|
|
|
|
build-check-exampleSite-zh:
|
|
|
|
jobs:
|
|
|
|
- build-check:
|
|
|
|
example-site-path: exampleSite/zh
|
|
|
|
theme-path: ../../..
|