From d9906ef40f1e113fcf51de4ad27c61aa45375c2d Mon Sep 17 00:00:00 2001 From: Tanya S <120410716+stubbsta@users.noreply.github.com> Date: Wed, 21 Jan 2026 15:02:53 +0200 Subject: [PATCH] Add TST info and Linea sepolia deploy instructions to readme (#50) * Add TST info and Linea sepolia deploy instructions to readme * Add list of expected contracts to be deployed * Fix linting * README updates --- README.md | 33 +++++++++++++++++++++++++-------- 1 file changed, 25 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index d485c88..9edf363 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# waku-rlnv2-contract [![Github Actions][gha-badge]][gha] [![Foundry][foundry-badge]][foundry] [![License: MIT][license-badge]][license] +# logos-messaging-rlnv2-contract [![Github Actions][gha-badge]][gha] [![Foundry][foundry-badge]][foundry] [![License: MIT][license-badge]][license] [gha]: https://github.com/waku-org/waku-rlnv2-contract/actions [gha-badge]: https://github.com/waku-org/waku-rlnv2-contract/actions/workflows/ci.yml/badge.svg @@ -7,7 +7,7 @@ [license]: https://opensource.org/licenses/MIT [license-badge]: https://img.shields.io/badge/License-MIT-blue.svg -Waku's RLNv2 contracts, which include - +logos-messaging's RLNv2 contracts, which include - - LazyIMT, which allows the root of the chain to be accessible on-chain. @@ -68,31 +68,48 @@ $ forge coverage #### Deploy to Anvil: +The following deployment will deploy several contracts required by the Logos Messaging RLNv2 contract and then deploy +the Logos Messaging RLNv2 implementation contract as well as a proxy contract. + ```sh $ TOKEN_ADDRESS=0x1122334455667788990011223344556677889900 forge script script/Deploy.s.sol --broadcast --rpc-url localhost --tc Deploy ``` -Replace the `TOKEN_ADDRESS` value by a token address you have deployed on anvil. A `TestToken` is available in -`test/TestToken.sol` and can be deployed with +Replace the `TOKEN_ADDRESS` value by a token address you have deployed on anvil. A `TestToken` implementation is +available in `test/TestStableToken.sol` and can be deployed with a proxy using the following command (use the proxy +address in the above command): ```sh -forge script test/TestToken.sol --broadcast --rpc-url localhost --tc TestTokenFactory +(ETH_FROM=$ETH_FROM forge script script/DeployTokenWithProxy.s.sol:DeployTokenWithProxy --broadcast -vvvv --rpc-url http://localhost --private-key $PRIVATE_KEY) ``` For this script to work, you need to have a `MNEMONIC` environment variable set to a valid [BIP39 mnemonic](https://iancoleman.io/bip39/). -#### Deploy to Sepolia: +#### Deploy to Linea Sepolia: Ensure that you use the [cast wallet](https://book.getfoundry.sh/reference/cast/cast-wallet) to store private keys that will be used in deployments. ```sh +$ export ETH_FROM= +$ export TOKEN_ADDRESS= $ export RPC_URL= -$ export ACCOUNT= -$ pnpm deploy:sepolia +$ export API_KEY_LINEASCAN= +$ export API_KEY_ETHERSCAN=123 #(dummy value) +$ export API_KEY_CARDONA=123 #(dummy value) +$ export ACCOUNT= +$ pnpm deploy:linea_sepolia ``` +This should deploy the following contracts: + +- PoseidonT3: used by the logos-messaging-rlnv2-contract to generate the cryptographic commitments stored in the merkle + tree +- LinearPriceCalculator: calculator used by logos-messaging-rlnv2-contract to determine the price of a membership +- WakuRlnV2: the implementation contract +- WakuRlnV2 Proxy: the proxy contract pointing to the implementation contract + ### Format Format the contracts: