-
Notifications
You must be signed in to change notification settings - Fork 0
/
action.yml
62 lines (56 loc) · 1.6 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
name: "rzk-check"
description: "Typecheck an Rzk project"
branding:
color: "purple"
icon: "triangle" # 2-simplex? :)
inputs:
system-rzk:
description: "Use system rzk (instead of downloading binaries)"
required: false
default: false
rzk-version:
description: "Version of Rzk to use (latest by default)"
required: false
default: "latest"
files:
description: "Files to check (rely on rzk.yaml by default)"
required: false
default: ""
typecheck:
description: "Enable typechecking the files (on by default)"
required: false
default: true
check-formatting:
description: "Enable checking the formatting (off by default)"
required: false
default: false
outputs:
rzk-version:
description: "Version of Rzk used"
value: ${{ steps.check-rzk-version.outputs.rzk-version }}
runs:
using: "composite"
steps:
- name: 🔨 Install Rzk proof assistant
uses: jaxxstorm/[email protected]
if: ${{ inputs.system-rzk == 'false' }}
with:
repo: fizruk/rzk
tag: ${{ inputs.rzk-version }}
rename-to: rzk
chmod: 0755
- name: Check Rzk version
shell: bash
id: check-rzk-version
run: |
echo "rzk-version=$(rzk version)" >> $GITHUB_OUTPUT
- name: 🔨 Check Rzk files definitions
shell: bash
if: ${{ inputs.typecheck == 'true' }}
run: |
rzk typecheck ${{ inputs.files }}
- name: 🔬 Check Rzk files formatting
shell: bash
if: ${{ inputs.check-formatting == 'true' }}
run: |
rzk format --check ${{ inputs.files }}