feat: add cpp circuit artifacts (#50)

This commit is contained in:
Nesopie
2025-02-10 18:11:03 +05:30
committed by GitHub
parent 451b99496f
commit 56126be376
3 changed files with 163 additions and 1 deletions

52
.github/workflows/artifacts.yml vendored Normal file
View File

@@ -0,0 +1,52 @@
name: OpenPassport CI/CD
on:
push:
branches:
- main
paths:
- "circuits/circuits/**"
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Install dependencies
run: |
npm i -g yarn && cd circuits && yarn
- name: Setup Rust
uses: dtolnay/rust-toolchain@stable
- name: Download Circom Binary v2.1.9
run: |
wget -qO /home/runner/work/circom https://github.com/iden3/circom/releases/download/v2.1.9/circom-linux-amd64
chmod +x /home/runner/work/circom
sudo mv /home/runner/work/circom /bin/circom
- name: Print Circom version
run: circom --version
- name: Install cpp dependencies
run: |
sudo apt-get update
sudo apt-get install --yes \
build-essential \
libgmp-dev \
libsodium-dev \
nasm \
nlohmann-json3-dev
- name: Build cpp circuits
run: |
chmod +x circuits/scripts/build/build_cpp.sh && \
./circuits/scripts/build/build_cpp.sh register &&
./circuits/scripts/build/build_cpp.sh disclose &&
./circuits/scripts/build/build_cpp.sh dsc
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: circuits
path: output/