-
Notifications
You must be signed in to change notification settings - Fork 1
65 lines (54 loc) · 1.79 KB
/
main.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
name: rust_tutorial_check
on:
push:
branches: [ master ]
paths-ignore:
- '**/README.md'
pull_request:
paths-ignore:
- '**/README.md'
concurrency:
group: ${{
( github.ref == 'refs/heads/master' &&
format('{0}/{1}', github.run_id, github.run_attempt) )
||
format('{0}/{1}', github.workflow, github.ref) }}
cancel-in-progress: true
jobs:
test-zkllvm-rust-workflow:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Install Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install zkLLVM DEB package
run: |
sudo bash -c "echo 'deb [trusted=yes] http://deb.nil.foundation/ubuntu/ all main' >>/etc/apt/sources.list"
sudo apt update
sudo apt install -y zkllvm proof-producer
- name: Install Rust zkLLVM toolchain
run: |
curl --proto '=https' --tlsv1.2 -O https://cdn.jsdelivr.net/gh/NilFoundation/zkllvm@master/rslang-installer.py
python3.10 rslang-installer.py --channel nightly
- name: Check the installation
run: |
rustc +zkllvm --version
assigner --version
- name: Build code
run: cargo +zkllvm build --release --target assigner-unknown-unknown --features=zkllvm
- name: Generate circuit and assignment table
run: |
assigner \
-b target/assigner-unknown-unknown/release/zkllvm-rust-template.ll \
-i inputs/example.inp \
-t assignment.tbl \
-c circuit.crct \
-e pallas
- name: Generate proof
run: |
proof-generator-single-threaded \
--circuit circuit.crct \
--assignment assignment.tbl \
--proof proof.bin