From 888524baae82d56edbf0c794e587de174906c34c Mon Sep 17 00:00:00 2001 From: Daehyun Paik Date: Wed, 7 Dec 2022 13:02:38 +0100 Subject: [PATCH] docs: add a badges to README.md --- README.md | 83 ++++++++++++++++++++++++++++++++++++-- circuits/README.md | 7 ++++ cli/README.md | 9 +++++ common/README.md | 6 +++ contracts/README.md | 9 +++++ core/README.md | 8 ++++ crypto/README.md | 8 ++++ domainobjs/README.md | 8 ++++ integrationTests/README.md | 8 ++++ server/README.md | 5 +++ 10 files changed, 148 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 01596d1c51..9e85c7c7bc 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,10 @@ # Minimal Anti-Collusion Infrastructure -[![CI](https://github.com/privacy-scaling-explorations/maci/actions/workflows/e2e.yml/badge.svg)](https://github.com/privacy-scaling-explorations/maci/actions/workflows/e2e.yml) +[![CI][cli-actions-badge]][cli-actions-link] +![License](https://img.shields.io/badge/license-MIT-green) +[![Telegram][telegram-badge]][telegram-link] + + Please refer to the original [ethresear.ch @@ -11,7 +15,23 @@ Documentation for developers and integrators can be found here: https://privacy-scaling-explorations.github.io/maci/ We welcome contributions to this project. Please join our -[Telegram group](https://t.me/joinchat/LUgOpE7J2gstRcZqdERyvw) to discuss. +[Telegram group][telegram-link] to discuss. + +## Packages + +Below you can find a list of the packages included in this repository. + +| package | npm | tests | +|---------|-----|--------| +| [maci-circuits][circuits-package] | [![NPM Package][circuits-npm-badge]][circuits-npm-link] | [![Actions Status][circuits-actions-badge]][circuits-actions-link] | +| [maci-cli][cli-package] | [![NPM Package][cli-npm-badge]][cli-npm-link] | [![Actions Status][cli-actions-badge]][cli-actions-link] | +| [maci-common][common-package] | [![NPM Package][common-npm-badge]][common-npm-link] | [![Actions Status][common-actions-badge]][common-actions-link] | +| [maci-contracts][contracts-package] | [![NPM Package][contracts-npm-badge]][contracts-npm-link] | [![Actions Status][contracts-actions-badge]][contracts-actions-link] | +| [maci-core][core-package] | [![NPM Package][core-npm-badge]][core-npm-link] | [![Actions Status][core-actions-badge]][core-actions-link] | +| [maci-crypto][crypto-package] | [![NPM Package][crypto-npm-badge]][crypto-npm-link] | [![Actions Status][crypto-actions-badge]][crypto-actions-link] | +| [maci-domainobjs][domainobjs-package] | [![NPM Package][domainobjs-npm-badge]][domainobjs-npm-link] | [![Actions Status][domainobjs-actions-badge]][domainobjs-actions-link] | +| [maci-integrationTests][integrationTests-package] | [![NPM Package][integrationTests-npm-badge]][integrationTests-npm-link] | [![Actions Status][integrationTests-actions-badge]][integrationTests-actions-link] | +| [maci-server][server-package] | [![NPM Package][server-npm-badge]][server-npm-link] | [![Actions Status][server-actions-badge]][server-actions-link] | ## Local Development and testing @@ -169,4 +189,61 @@ Note: a cached version of `builder` job must be on your system prior as it relie ### CI pipeline -CI pipeline ensures that we have automated tests that constantly validate. For more information about pipeline workflows, see https://github.com/privacy-scaling-explorations/maci/wiki/MACI-CI-pipeline. \ No newline at end of file +CI pipeline ensures that we have automated tests that constantly validate. For more information about pipeline workflows, see https://github.com/privacy-scaling-explorations/maci/wiki/MACI-CI-pipeline. + +[telegram-badge]: https://badges.aleen42.com/src/telegram.svg +[telegram-link]: https://t.me/joinchat/LUgOpE7J2gstRcZqdERyvw + +[circuits-package]: ./circuits +[circuits-npm-badge]: https://img.shields.io/npm/v/maci-circuits.svg +[circuits-npm-link]: https://www.npmjs.com/package/maci-circuits +[circuits-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/circuit-build.yml/badge.svg +[circuits-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3ACircuit + +[cli-package]: ./cli +[cli-npm-badge]: https://img.shields.io/npm/v/maci-cli.svg +[cli-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/e2e.yml/badge.svg +[cli-npm-link]: https://www.npmjs.com/package/maci-cli +[cli-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3ACI + +[common-package]: ./common +[common-npm-badge]: https://img.shields.io/npm/v/maci-common.svg +[common-npm-link]: https://www.npmjs.com/package/maci-common +[common-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/build.yml/badge.svg +[common-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Acommon + +[contracts-package]: ./contracts +[contracts-npm-badge]: https://img.shields.io/npm/v/maci-contracts.svg +[contracts-npm-link]: https://www.npmjs.com/package/maci-contracts +[contracts-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/contracts-build.yml/badge.svg +[contracts-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Acontracts + +[core-package]: ./core +[core-npm-badge]: https://img.shields.io/npm/v/maci-core.svg +[core-npm-link]: https://www.npmjs.com/package/maci-core +[core-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/core-build.yml/badge.svg +[core-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Acore + +[crypto-package]: ./crypto +[crypto-npm-badge]: https://img.shields.io/npm/v/maci-crypto.svg +[crypto-npm-link]: https://www.npmjs.com/package/maci-crypto +[crypto-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/crypto-build.yml/badge.svg +[crypto-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Acrypto + +[domainobjs-package]: ./domainobjs +[domainobjs-npm-badge]: https://img.shields.io/npm/v/maci-domainobjs.svg +[domainobjs-npm-link]: https://www.npmjs.com/package/maci-domainobjs +[domainobjs-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/domainobjs-build.yml/badge.svg +[domainobjs-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Adomainobjs + +[integrationTests-package]: ./integrationTests +[integrationTests-npm-badge]: https://img.shields.io/npm/v/maci-integrationtests.svg +[integrationTests-npm-link]: https://www.npmjs.com/package/maci-integrationtests +[integrationTests-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/e2e.yml/badge.svg +[integrationTests-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3ACI + +[server-package]: ./server +[server-npm-badge]: https://img.shields.io/npm/v/maci-server.svg +[server-npm-link]: https://www.npmjs.com/package/maci-server +[server-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/build.yml/badge.svg +[server-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Aserver diff --git a/circuits/README.md b/circuits/README.md index 5e3c8297b8..2d667edc13 100644 --- a/circuits/README.md +++ b/circuits/README.md @@ -1,5 +1,8 @@ # Circuits +[![NPM Package][circuits-npm-badge]][circuits-npm-link] +[![Actions Status][circuits-actions-badge]][circuits-actions-link] + This package contains the zk-SNARK circuits written in Circom 2.0. The main circuits are: @@ -24,3 +27,7 @@ In order to test the circuits package follow the instructions below: 3. run `npm run test` to run all tests or add `-$CIRCUIT_NAME` to test individually (e.g. `npm run test-processMessages`) +[circuits-npm-badge]: https://img.shields.io/npm/v/maci-circuits.svg +[circuits-npm-link]: https://www.npmjs.com/package/maci-circuits +[circuits-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/circuit-build.yml/badge.svg +[circuits-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3ACircuit diff --git a/cli/README.md b/cli/README.md index 96a40931e9..c7f0a88e8c 100644 --- a/cli/README.md +++ b/cli/README.md @@ -1,4 +1,13 @@ # maci-cli +[![NPM Package][cli-npm-badge]][cli-npm-link] +[![Actions Status][cli-actions-badge]][cli-actions-link] + Please refer to the [documentation for the CLI](http://privacy-scaling-explorations.github.io/maci/cli.html). + + +[cli-npm-badge]: https://img.shields.io/npm/v/maci-cli.svg +[cli-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/e2e.yml/badge.svg +[cli-npm-link]: https://www.npmjs.com/package/maci-cli +[cli-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3ACI \ No newline at end of file diff --git a/common/README.md b/common/README.md index 6e4ab7bda4..62c46bf784 100644 --- a/common/README.md +++ b/common/README.md @@ -1,4 +1,10 @@ # maci-common +[![NPM Package][common-npm-badge]][common-npm-link] + + This submodule contains utility/helper functions used by other maci submodules. +[common-npm-badge]: https://img.shields.io/npm/v/maci-common.svg +[common-npm-link]: https://www.npmjs.com/package/maci-common + diff --git a/contracts/README.md b/contracts/README.md index 856e7f6431..8b034ace50 100644 --- a/contracts/README.md +++ b/contracts/README.md @@ -1,5 +1,8 @@ # `maci-contracts` +[![NPM Package][contracts-npm-badge]][contracts-npm-link] +[![Actions Status][contracts-actions-badge]][contracts-actions-link] + This submodule contains all the Ethereum contracts and tests for MACI. For more information please refer to the [documentation for Contracts](http://privacy-scaling-explorations.github.io/maci/contracts.html). @@ -47,3 +50,9 @@ For more information please refer to the [documentation for Contracts](http://pr * **`HasherBenchmarks/`** - Contract with testing and gas benchmark functions only for development purposes + + +[contracts-npm-badge]: https://img.shields.io/npm/v/maci-contracts.svg +[contracts-npm-link]: https://www.npmjs.com/package/maci-contracts +[contracts-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/contracts-build.yml/badge.svg +[contracts-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Acontracts diff --git a/core/README.md b/core/README.md index 9820896f0b..dc2dc30b22 100644 --- a/core/README.md +++ b/core/README.md @@ -1,5 +1,8 @@ # `maci-core` +[![NPM Package][core-npm-badge]][core-npm-link] +[![Actions Status][core-actions-badge]][core-actions-link] + This submodule assists with handling key business logic functions and processes. @@ -96,3 +99,8 @@ main root) whenever the MACI contract's `mergeMessageAqSubRoots()` and They should contain the same leaves, even if the `messageAq` is not yet merged. `messageTree` exists for developer convenience. + +[core-npm-badge]: https://img.shields.io/npm/v/maci-core.svg +[core-npm-link]: https://www.npmjs.com/package/maci-core +[core-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/core-build.yml/badge.svg +[core-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Acore diff --git a/crypto/README.md b/crypto/README.md index c227645721..f93bd19365 100644 --- a/crypto/README.md +++ b/crypto/README.md @@ -1,5 +1,8 @@ # maci-crypto +[![NPM Package][crypto-npm-badge]][crypto-npm-link] +[![Actions Status][crypto-actions-badge]][crypto-actions-link] + This module implements abstractions over cryptographic functions which MACI employs. @@ -122,3 +125,8 @@ hash4( i_11, ) ``` + +[crypto-npm-badge]: https://img.shields.io/npm/v/maci-crypto.svg +[crypto-npm-link]: https://www.npmjs.com/package/maci-crypto +[crypto-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/crypto-build.yml/badge.svg +[crypto-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Acrypto diff --git a/domainobjs/README.md b/domainobjs/README.md index 4e7c93d8ed..38abb88e14 100644 --- a/domainobjs/README.md +++ b/domainobjs/README.md @@ -1,5 +1,8 @@ # maci-domainobjs +[![NPM Package][domainobjs-npm-badge]][domainobjs-npm-link] +[![Actions Status][domainobjs-actions-badge]][domainobjs-actions-link] + This module implements domain objects. A domain object is: > a logical container of purely domain information, usually represents a @@ -58,3 +61,8 @@ Encapsulates a Groth16 zk-SNARK verifying key. ## `Proof` Encapsulates a Groth16 zk-SNARK proof. + +[domainobjs-npm-badge]: https://img.shields.io/npm/v/maci-domainobjs.svg +[domainobjs-npm-link]: https://www.npmjs.com/package/maci-domainobjs +[domainobjs-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/domainobjs-build.yml/badge.svg +[domainobjs-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3Adomainobjs diff --git a/integrationTests/README.md b/integrationTests/README.md index f4f0e5a3f1..ac46fc9f36 100644 --- a/integrationTests/README.md +++ b/integrationTests/README.md @@ -1,6 +1,14 @@ # maci-integrationTests +[![NPM Package][integrationTests-npm-badge]][integrationTests-npm-link] +[![Actions Status][integrationTests-actions-badge]][integrationTests-actions-link] + This submodule contains test suites that span between different submodules. The current approach that it takes is to test each CLI command and also chain them together. + +[integrationTests-npm-badge]: https://img.shields.io/npm/v/maci-integrationtests.svg +[integrationTests-npm-link]: https://www.npmjs.com/package/maci-integrationtests +[integrationTests-actions-badge]: https://github.com/privacy-scaling-explorations/maci/actions/workflows/e2e.yml/badge.svg +[integrationTests-actions-link]: https://github.com/privacy-scaling-explorations/maci/actions?query=workflow%3ACI diff --git a/server/README.md b/server/README.md index 99e44541a9..96176e2940 100644 --- a/server/README.md +++ b/server/README.md @@ -1,3 +1,5 @@ +[![NPM Package][server-npm-badge]][server-npm-link] + ## Local Development ### Setup @@ -88,3 +90,6 @@ cd server # v0.10 ./user_v0_10.sh signup -p $pk -x $maci ``` + +[server-npm-badge]: https://img.shields.io/npm/v/maci-server.svg +[server-npm-link]: https://www.npmjs.com/package/maci-server