-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhardhat.config.js
97 lines (95 loc) · 2.33 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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
require('@nomicfoundation/hardhat-toolbox')
require('@nomiclabs/hardhat-ethers')
require('@openzeppelin/hardhat-upgrades')
require('hardhat-contract-sizer')
require('path')
const dotenv = require('dotenv')
dotenv.config({ path: './.env' })
/** @type import('hardhat/config').HardhatUserConfig */
module.exports = {
solidity: {
version: '0.8.12',
settings: {
optimizer: {
enabled: true,
runs: 1,
details: {
yul: true
}
},
viaIR: true
}
},
mocha: {
timeout: 100000000
},
contractSizer: {
alphaSort: true,
runOnCompile: true,
disambiguatePaths: false
},
networks: {
ethereum: {
url: `https://eth.llamarpc.com`,
accounts: [process.env.ETH_PRIVATE_KEY]
},
polygon: {
url: `https://polygon-rpc.com`,
accounts: [process.env.POLYGON_PRIVATE_KEY]
},
goerli: {
url: `https://goerli.infura.io/v3/${process.env.WEB3_INFURA_PROJECT_ID}`,
accounts: [process.env.GOERLI_PRIVATE_KEY]
},
mumbai: {
url: `https://polygon-mumbai.infura.io/v3/${process.env.WEB3_INFURA_PROJECT_ID}`,
accounts: [process.env.MUMBAI_PRIVATE_KEY]
},
bsc_testnet: {
url: `https://endpoints.omniatech.io/v1/bsc/testnet/public`,
accounts: [process.env.BSC_TEST_PRIVATE_KEY]
}
},
etherscan: {
apiKey: {
polygon: process.env.POLYGONSCAN_TOKEN,
polygonMumbai: process.env.POLYGONSCAN_TOKEN,
goerli: process.env.ETHERSCAN_TOKEN,
etherum: process.env.ETHERSCAN_TOKEN,
},
customChains: [
{
network: 'goerli',
chainId: 5,
urls: {
apiURL: 'http://api-goerli.etherscan.io/api',
browserURL: 'https://goerli.etherscan.io/'
}
},
{
network: 'etherum',
chainId: 1,
urls: {
apiURL: 'https:/api.etherscan.io/api',
browserURL: 'https://etherscan.io/'
}
},
{
network: 'mumbai',
chainId: 80001,
urls: {
apiURL: 'https://api-testnet.polygonscan.com/api',
browserURL: 'https://mumbai.polygonscan.com/'
}
},
{
network: 'bsc_testnet',
chainId: 97,
urls: {
apiURL: 'https:/api-testnet.bscscan.com/api',
browserURL: 'https://bscscan.com/'
}
}
]
}
}