-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhardhat.config.ts
executable file
·98 lines (94 loc) · 2.57 KB
/
hardhat.config.ts
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
98
import 'dotenv/config'
import '@nomiclabs/hardhat-ethers'
import '@nomiclabs/hardhat-waffle'
import '@nomiclabs/hardhat-etherscan'
import '@openzeppelin/hardhat-upgrades'
import 'hardhat-typechain'
import { HardhatUserConfig } from 'hardhat/types'
const privateKey = process.env.PRIVATE_KEY
const infuraKey = process.env.INFURA_KEY
const rpcURL = process.env.RPC_URL
const config: HardhatUserConfig = {
defaultNetwork: 'hardhat',
solidity: {
compilers: [
{
version: '0.8.0',
settings: {
optimizer: {
enabled: true,
runs: 200,
},
},
},
{
version: '0.6.6',
settings: {
optimizer: {
enabled: true,
runs: 200,
},
},
},
{
version: '0.6.0',
settings: {
optimizer: {
enabled: true,
runs: 200,
},
},
},
{
version: '0.5.0',
settings: {
optimizer: {
enabled: true,
runs: 200,
},
},
},{
version: '0.8.0',
settings: {
optimizer: {
enabled: true,
runs: 200,
},
},
},
],
},
networks: {
hardhat: {},
kovan: {
url: `https://kovan.infura.io/v3/${infuraKey}`,
accounts: [`0x${privateKey}`],
gasPrice: 1000000000,
},
rinkeby: {
url: `https://rinkeby.infura.io/v3/${infuraKey}`,
accounts: [`0x${privateKey}`],
gasPrice: 1000000000,
},
ropsten: {
url: `https://ropsten.infura.io/v3/${infuraKey}`,
accounts: [`0x${privateKey}`],
gasPrice: 1000000000,
},
mainnet: {
url: `https://mainnet.infura.io/v3/${infuraKey}`,
accounts: [`0x${privateKey}`],
gasPrice: 1000000000,
},
fantomTestnet: {
url: rpcURL,
accounts: [`0x${privateKey}`],
chainId: 0xfa2
}
},
typechain: {
outDir: 'typechain',
target: 'ethers-v5',
},
}
export default config