LoveIt/.circleci/config.yml
2020-02-16 22:31:06 +08:00

33 lines
918 B
YAML

version: 2.1
jobs:
build-check:
parameters:
example-site-path:
type: string
theme-path:
type: string
docker:
- image: cibuilds/hugo:0.64
working_directory: ~/LoveIt
steps:
- checkout
- run: git submodule sync
- run: git submodule update --init
- run: cd << parameters.example-site-path >>
- run:
name: "Run Hugo"
command: HUGO_ENV=production hugo --themesDir << parameters.theme-path >> -v --minify --gc
- run:
name: "Test Website"
command: htmlproofer public --allow-hash-href --empty-alt-ignore --disable-external
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: ../../..