Skip to content

Latest commit

 

History

History
37 lines (23 loc) · 1 KB

README.md

File metadata and controls

37 lines (23 loc) · 1 KB

Hardhat Etherscan

This template demonstrates a basic Hardhat project, along with the Hardhat Verify plugin to automate contract verification on Etherscan-like explorers.

Prerequisite

Uses dotenv for management of private keys, node URLs and other sensitive information, rename .env.sample to .env.

Then populate the fields with your own private key and node connections such as from Chainlist.

Setup

  1. Install Hardhat and all dependencies
npm 1
  1. Compile the contracts
npx hardhat compile
  1. Deploy to a specific network, such as Goerli/Sepolia/Polygon etc

Refer to hardhat.config.js under the networks section for chain names or to add new ones.

npx hardhat run scripts/deploy.js --network sepolia
  1. Verify the contract
npx hardhat verify 0x8f4877a367dc6dfaad8415ddd249af688b17d23fe049662b99814dff40c83dde --network sepolia