-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathhardhat.config.ts
More file actions
60 lines (55 loc) · 1.25 KB
/
hardhat.config.ts
File metadata and controls
60 lines (55 loc) · 1.25 KB
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
import "@nomiclabs/hardhat-waffle";
import 'solidity-coverage';
import dotenv from "dotenv";
dotenv.config();
import { task, HardhatUserConfig } from "hardhat/config";
const { ARCHIVE_URL, MNEMONIC } = process.env;
if (!ARCHIVE_URL)
throw new Error(
`ARCHIVE_URL env var not set. Copy .env.template to .env and set the env var`
);
if (!MNEMONIC)
throw new Error(
`MNEMONIC env var not set. Copy .env.template to .env and set the env var`
);
const accounts = {
// derive accounts from mnemonic, see tasks/create-key
mnemonic: MNEMONIC,
path:"m/44'/60'/0'/0",
initialIndex: 0,
count: 20
};
// Go to https://hardhat.org/config/ to learn more
const config: HardhatUserConfig = {
solidity: {
compilers: [
{ version: "0.4.21" },
{ version: "0.8.11" },
{ version: "0.7.3" }
],
},
networks: {
ropsten: {
url: ARCHIVE_URL,
accounts,
gas: 2100000,
gasPrice: 30005088383,
},
hardhat: {
accounts,
forking: {
url: ARCHIVE_URL,
// blockNumber: 11760848,
// blockNumber: 11823465,
enabled: true
},
gas: 2100000,
gasPrice: 30005088383,
gasMultiplier: 1
},
},
mocha: {
timeout: 300 * 1e3,
}
};
export default config;