package
0.0.0-20240717054907-49ac26ede64e
Repository: https://github.com/cryptoriums/packages.git
Documentation: pkg.go.dev

# README

Local Node

Hardhat or Anvil(Foundry) local nodes

ctx := context.Background()
logger := logging.NewLogger()
nodeURL := os.GetEnv("NODE_URL")
blockNumber := "14675022"

ln, err := localnode.New(logger, localnode.Anvil, nodeURL, "13858047")
if err != nil {
    log.Fatal(err)
}
defer ln.Stop()

client, err := ethclient.DialContext(ctx, ln.GetNodeURL())
if err != nil {
    log.Fatal(err)
}

err = ln.ReplaceContract(
    ctx,
    "../testing/contracts/source/Booster.sol",
    "Booster",
    common.HexToAddress("0xf403c135812408bfbe8713b5a23a04b3d48aae31"),
)
if err != nil {
    log.Fatal(err)
}

# Functions

No description provided by the author

# Constants

No description provided by the author

# Variables

No description provided by the author
No description provided by the author

# Structs

No description provided by the author

# Type aliases

No description provided by the author