mirror of
https://github.com/logos-messaging/js-waku.git
synced 2026-01-02 13:53:12 +00:00
feat: use wagmi to generate contract types
This commit is contained in:
parent
8221064d4f
commit
7d386cecb7
3
.gitmodules
vendored
Normal file
3
.gitmodules
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
[submodule "packages/rln/waku-rlnv2-contract"]
|
||||
path = packages/rln/waku-rlnv2-contract
|
||||
url = git@github.com:waku-org/waku-rlnv2-contract.git
|
||||
1530
package-lock.json
generated
1530
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -62,6 +62,7 @@
|
||||
"@waku/build-utils": "^1.0.0",
|
||||
"@waku/interfaces": "0.0.34",
|
||||
"@waku/message-encryption": "^0.0.37",
|
||||
"@wagmi/cli": "^2.7.0",
|
||||
"deep-equal-in-any-order": "^2.0.6",
|
||||
"fast-check": "^3.23.2",
|
||||
"rollup-plugin-copy": "^3.5.0"
|
||||
|
||||
30
packages/rln/setup-contract-abi.sh
Executable file
30
packages/rln/setup-contract-abi.sh
Executable file
@ -0,0 +1,30 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
||||
SUBMODULE_DIR="$SCRIPT_DIR/waku-rlnv2-contract"
|
||||
|
||||
echo "Setting up waku-rlnv2-contract submodule..."
|
||||
|
||||
# Initialize submodule if needed
|
||||
if [ ! -d "$SUBMODULE_DIR/.git" ]; then
|
||||
echo "Initializing submodule..."
|
||||
cd "$SCRIPT_DIR/../.."
|
||||
git submodule update --init --recursive packages/rln/waku-rlnv2-contract
|
||||
fi
|
||||
|
||||
# Install dependencies
|
||||
echo "Installing submodule dependencies..."
|
||||
cd "$SUBMODULE_DIR"
|
||||
npm install
|
||||
|
||||
# Build contracts with Foundry
|
||||
echo "Building contracts with Foundry..."
|
||||
forge build
|
||||
|
||||
# Generate ABIs
|
||||
echo "Generating contract ABIs..."
|
||||
cd "$SCRIPT_DIR"
|
||||
npx wagmi generate
|
||||
|
||||
echo "✅ Contract ABI setup complete!"
|
||||
Loading…
x
Reference in New Issue
Block a user