npx hardhat run scripts/deploy.js [--network]
npm install --save-dev @nomiclabs/hardhat-etherscan
npx hardhat verify --network [network] [contract address] [constructor params, if any]
Create a .env
file at root level and add the following variables:
ALCHEMY_API_KEY
ALCHEMY_API_KEY_ROPSTEN
ALCHEMY_API_KEY_POLYGON
ETHERSCAN_API_KEY
METAMASK_PRIVATE_KEY