From 19f916e6fd0d62b10d12c5353da6daaf15920b90 Mon Sep 17 00:00:00 2001 From: poma Date: Fri, 12 Jul 2019 13:55:23 +0300 Subject: [PATCH] circuit build scripts --- package.json | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/package.json b/package.json index e30143a..ad9d783 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,11 @@ "description": "", "main": "index.js", "scripts": { + "build:circuit:compile": "circom circuits/withdraw.circom -o build/circuits/withdraw.json && snarkjs info -c build/circuits/withdraw.json", + "build:circuit:setup": "snarkjs setup --protocol groth -c build/circuits/withdraw.json --pk build/circuits/withdraw_proving_key.json --vk build/circuits/withdraw_verification_key.json", + "build:circuit:contract": "snarkjs generateverifier -v build/circuits/withdraw_verifier.sol --vk build/circuits/withdraw_verification_key.json", + "build:circuit": "mkdir -p build/circuits && npm run build:circuit:compile && npm run build:circuit:setup && npm run build:circuit:contract", + "build:contract": "truffle compile", "test": "echo \"Error: no test specified\" && exit 1" }, "keywords": [],