-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathaction.yml
73 lines (72 loc) · 2.03 KB
/
action.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
#Still depends on triggering default gh deploy actions
name: zola-action
description: Build, check, and/or deploy a zola site
author: Kenzi Connor
branding:
icon: align-justify
color: orange
inputs:
root:
description: Directory to use as root of project. Deploy does not like this and requires an addition checkout in root
required: false
default: '.'
type: string
config:
description: Path to a config file other than config.toml in the root of project
required: false
default: 'config.toml'
type: string
base-url:
description: Force the base URL to be that value (defaults to the one in config)
required: false
default: ''
type: string
drafts:
description: Include drafts when loading the site
required: false
default: false
type: boolean
output-dir:
description: Outputs the generated site in the given path (by default 'public' dir in project root)
required: false
default: 'public'
type: string
force:
description: Force building the site even if output directory is non-empty
required: false
default: false
type: boolean
deploy:
description: Push to GitHub-Pages using JamesIves/github-pages-deploy-action defaults
required: false
default: true
type: boolean
check:
description: Check external links with `zola check`
required: false
default: true
type: boolean
runs:
using: composite
steps:
- name: zola check
if: inputs.check
uses: zolacti/on@check
with:
root: ${{inputs.root}}
config: ${{inputs.config}}
drafts: ${{inputs.drafts}}
- name: zola build
uses: zolacti/on@build
with:
root: ${{inputs.root}}
config: ${{inputs.config}}
base-url: ${{inputs.base-url}}
drafts: ${{inputs.drafts}}
output-dir: ${{inputs.output-dir}}
force: ${{inputs.force}}
- name: Deploy 🚀
if: inputs.deploy
uses: JamesIves/github-pages-deploy-action@v4
with:
folder: ${{inputs.output-dir}}