diff --git a/crates/contracts/anvil/filter_anvil_state.sh b/crates/contracts/anvil/filter_anvil_state.sh new file mode 100755 index 000000000..a38460ca7 --- /dev/null +++ b/crates/contracts/anvil/filter_anvil_state.sh @@ -0,0 +1,9 @@ +#!/bin/bash + +ANVIL_STATE=$1 + +# Remove the fields transactions, blocks block.prevrandao and block.timestamp +jq 'del(.transactions)' $ANVIL_STATE > temp.json && cat temp.json > $ANVIL_STATE +jq 'del(.blocks)' $ANVIL_STATE > temp.json && cat temp.json > $ANVIL_STATE +jq 'del(.block.prevrandao)' $ANVIL_STATE > temp.json && cat temp.json > $ANVIL_STATE +jq 'del(.block.timestamp)' $ANVIL_STATE > temp.json && cat temp.json > $ANVIL_STATE