-
Notifications
You must be signed in to change notification settings - Fork 0
/
hardhat.config.ts
57 lines (54 loc) · 1.36 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
import { HardhatUserConfig } from "hardhat/config";
import "@nomicfoundation/hardhat-toolbox";
import "@openzeppelin/hardhat-upgrades";
import "hardhat-contract-sizer";
import "hardhat-gas-reporter";
import dotenv from "dotenv";
dotenv.config();
const config: HardhatUserConfig = {
solidity: {
version: process.env.SOLIDITY_VERSION ?? "",
settings: {
optimizer: {
enabled: process.env.OPTIMIZER_ENABLED === "true",
runs: Number(process.env.OPTIMIZER_RUNS)
}
}
},
networks: {
hardhat: {
accounts: {
mnemonic: process.env.HARDHAT_MNEMONIC
}
},
ganache: {
url: process.env.GANACHE_RPC,
accounts: {
mnemonic: process.env.GANACHE_MNEMONIC
}
},
cw_testnet: {
url: process.env.CW_TESTNET_RPC,
accounts: process.env.CW_TESTNET_PK
? [process.env.CW_TESTNET_PK]
: {
mnemonic: process.env.CW_TESTNET_MNEMONIC ?? ""
}
},
cw_mainnet: {
url: process.env.CW_MAINNET_RPC,
accounts: process.env.CW_MAINNET_PK
? [process.env.CW_MAINNET_PK]
: {
mnemonic: process.env.CW_MAINNET_MNEMONIC ?? ""
}
}
},
gasReporter: {
enabled: process.env.GAS_REPORTER_ENABLED === "true"
},
contractSizer: {
runOnCompile: process.env.CONTRACT_SIZER_ENABLED === "true"
}
};
export default config;