generated from smartcontractkit/foundry-starter-kit
-
Notifications
You must be signed in to change notification settings - Fork 0
/
hardhat.config.js
58 lines (53 loc) · 1.34 KB
/
hardhat.config.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
const config = require("dotenv").config();
require("@nomicfoundation/hardhat-foundry");
require("@nomicfoundation/hardhat-toolbox");
require("@dgma/hardhat-sol-bundler");
require("./tasks");
const { ZeroHash } = require("ethers");
const deployments = require("./deployment.config");
if (config.error) {
console.error(config.error);
}
const deployerAccounts = [config?.parsed?.PRIVATE_KEY || ZeroHash];
const DEFAULT_RPC = "https:random.com";
/** @type import('hardhat/config').HardhatUserConfig */
module.exports = {
solidity: {
compilers: [{ version: "0.8.20" }],
metadata: {
appendCBOR: false,
},
},
paths: {
sources: "src",
tests: "test",
},
networks: {
hardhat: {
deployment: deployments.hardhat,
},
localhost: {
deployment: deployments.localhost,
},
"arbitrum-sepolia": {
url: config?.parsed?.ARBITRUM_SEPOLIA_RPC || DEFAULT_RPC,
accounts: deployerAccounts,
deployment: deployments["arbitrum-sepolia"],
},
},
etherscan: {
apiKey: {
"arbitrum-sepolia": config?.parsed?.ABISCAN_API_KEY,
},
customChains: [
{
network: "arbitrum-sepolia",
chainId: 421614,
urls: {
apiURL: "https://api-sepolia.arbiscan.io/api",
browserURL: "https://sepolia-explorer.arbitrum.io",
},
},
],
},
};