Bxpana
@bxpana
🤔 Curious about your token balances on @ZKsync ? Let's use Foundry's cast tool to check balances directly from the command line! Quick, efficient, and no GUI needed. 🧵👇
0 reply
0 recast
0 reaction
Bxpana
@bxpana
Step 1: Use a Rich Wallet When you run `era_test_node fork mainnet` it provides you with rich wallets preloaded with ETH on the ZKsync mainnet fork. Let's use one of these for testing!
0 reply
0 recast
0 reaction
Bxpana
@bxpana
Step 2: Add Rich Wallet to .env Update your .env file with the rich wallet's address and private key. This way, you have funds to play with on your local fork. Remember, never use real private keys for testing! 🔑
0 reply
0 recast
0 reaction
Bxpana
@bxpana
Step 3: Load the Environment Variables In your terminal, load the variables (you’ll need to do this anytime changes are made to your .env) and verify they are set. You should see your rich wallet's address and private key. ✅
0 reply
0 recast
0 reaction
Bxpana
@bxpana
Step 4: Check ETH Balance Now, check your ETH balance. You'll see your balance in wei. To convert to ETH, divide by 1e18. ➗ You can use something like https://eth-converter.com as well
0 reply
0 recast
0 reaction