diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml new file mode 100644 index 0000000..7d5779f --- /dev/null +++ b/.github/workflows/gh-pages.yml @@ -0,0 +1,25 @@ +name: github pages + +on: + push: + branches: + - master + +jobs: + deploy: + runs-on: ubuntu-18.04 + steps: + - uses: actions/checkout@v2 + + - name: Setup mdBook + uses: peaceiris/actions-mdbook@v1 + with: + mdbook-version: 'latest' + + - run: mdbook build + + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./gh-pages diff --git a/.gitignore b/.gitignore index ea8c4bf..f7957a7 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ -/target +target +gh-pages diff --git a/README.md b/README.md deleted file mode 100644 index c3abb94..0000000 --- a/README.md +++ /dev/null @@ -1,30 +0,0 @@ -# Megaclite - -Megaclite is a zero-knowledge proof tool set building for the Polkadot ecology. - -## Curves - -Here we provide `alt_bn128` and `bls12_381` curves for the ZKP, both of them contains `Integrate addition`, -`Scalar multiplication` and `Pairing` functions, for help devlopers trying and testing these tools, we -provide `groth16` for verifaction as well. - - -## Runtime Interface - -TODO - -## Ink! - -TODO - - - -## References - -+ [alt\_bn128][alt_bn128] -+ [bls12\_381][bls12_381] -+ [groth16][groth16] - -[alt_bn128]: https://github.com/zcash-hackworks/bn -[bls12_381]: https://github.com/zkcrypto/bls12_381 -[groth16]: http://www.zeroknowledgeblog.com/index.php/groth16 diff --git a/README.md b/README.md new file mode 120000 index 0000000..891536a --- /dev/null +++ b/README.md @@ -0,0 +1 @@ +book/README.md \ No newline at end of file diff --git a/book.toml b/book.toml new file mode 100644 index 0000000..7123b42 --- /dev/null +++ b/book.toml @@ -0,0 +1,14 @@ +[book] +authors = ["Megaclite"] +language = "en" +multilingual = false +src = "book" +title = "Megaclite" + +[build] +build-dir = "gh-pages" + +[output.html] +default-theme = "dark" +preferred-dark-theme = "ayu" +git-repository-url = "https://github.com/patractlabs/megaclite" diff --git a/book/README.md b/book/README.md new file mode 100644 index 0000000..99b6187 --- /dev/null +++ b/book/README.md @@ -0,0 +1,32 @@ +# Megaclite + +Megaclite is a zero-knowledge proof tool set building for the Polkadot ecology. + +## Curves + +Here we provide `alt_bn128` and `bls12_381` curves for ZKP, both of them contain `Integrate addition`, +`Scalar multiplication` and `Pairing` functions, for helping devlopers trying and testing the curves, +we provide `groth16` for verifaction as well. + + +## Runtime Interfaces + ++ [jupiter-contracts][jupiter-contracts] + + +## Ink! + ++ [jupiter-ink-env][jupiter-ink-env] + + +## References + ++ [alt\_bn128][alt_bn128] ++ [bls12\_381][bls12_381] ++ [groth16][groth16] + +[alt_bn128]: https://github.com/zcash-hackworks/bn +[bls12_381]: https://github.com/zkcrypto/bls12_381 +[groth16]: http://www.zeroknowledgeblog.com/index.php/groth16 +[jupiter-contracts]: https://github.com/patractlabs/substrate/tree/contracts/frame/contracts +[jupiter-ink-env]: https://github.com/patractlabs/ink/tree/altbn128/env/crates/env diff --git a/book/SUMMARY.md b/book/SUMMARY.md new file mode 100644 index 0000000..cebd4a7 --- /dev/null +++ b/book/SUMMARY.md @@ -0,0 +1,3 @@ +# Summary + +[Intro](./README.md) diff --git a/src/lib.rs b/src/lib.rs index e7a11a9..6a3a86d 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -1,3 +1,4 @@ -fn main() { - println!("Hello, world!"); +#[test] +fn test() { + println!("XIX"); }