mirror of
https://github.com/zkopru-network/zkopru.git
synced 2026-02-19 10:04:41 -05:00
c3b9bb2d06ba77266d61b784b15028cd772ccb23
zkopru
[WIP]
What is zkopru?
[WIP]
How to run cli-wallet of zkopru?
npm install -g @zkopru/cli-wallet
zkopru-wallet
How to run coordinator of zkopru?
npm install -g @zkopru/coordinator
zkopru-wallet --ws
zkopru-coordinator
Development
Prerequisites
-
You need docker & docker-compose for integration test
- Get docker
- Get docker-compose
-
Set your node version v12. It currently supports Node v12.
- Get nvm here
- Download node version 12 and set to use it.
If you want to make node 12 as the default option run && yarn build:keys
nvm install 12 nvm use 12nvm alias default 12
-
Install yarn globally. You can skip this step if you already have yarn.
npm install -g yarn
Build
-
Install packages
yarn -
Build packages
yarn build
Run
-
Prepare three terminals
-
Run ganache and deploy contract by one-click.
docker-compose up --build testnet -
Go to cooridnator package and run coordinator with a pre-configured test account.
cd packages/coordinator && yarn dev:configThis will give you a cli menu to operate coordinator locally.
-
Go to the cli-wallet package and run wallet with a pre-configured test account.
cd packages/cli-wallet && yarn dev:configThis will give you a cli menu to run cli-wallet locally.
Optional commands
Fresh build
yarn build:fresh
This command will re-build the whole packages by wiping away every artifacts.
Setting up new snark keys
yarn build:keys
Testing
yarn test
Module dev
lerna run build --scope=@zkopru/modulename
lerna run test --scope=@zkopru/modulename
Languages
TypeScript
79.2%
Solidity
15.7%
JavaScript
2.4%
Circom
1.8%
Dockerfile
0.6%
Other
0.3%