forked from ArtBlocks/artblocks-contracts
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhardhat.config.ts
110 lines (106 loc) · 2.58 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
99
100
101
102
103
104
105
106
107
108
109
110
require("dotenv").config();
import "@nomiclabs/hardhat-waffle";
import "@nomiclabs/hardhat-truffle5";
import "hardhat-gas-reporter";
import "solidity-coverage";
import "@nomiclabs/hardhat-solhint";
import "hardhat-contract-sizer";
import "@nomiclabs/hardhat-etherscan";
import "hardhat-docgen";
const MAINNET_JSON_RPC_PROVIDER_URL = process.env.MAINNET_JSON_RPC_PROVIDER_URL;
const GOERLI_JSON_RPC_PROVIDER_URL = process.env.GOERLI_JSON_RPC_PROVIDER_URL;
const MAINNET_PRIVATE_KEY = process.env.MAINNET_PRIVATE_KEY;
const TESTNET_PRIVATE_KEY = process.env.TESTNET_PRIVATE_KEY;
const ETHERSCAN_API_KEY = process.env.ETHERSCAN_API_KEY;
// You need to export an object to set up your config
// Go to https://hardhat.org/config/ to learn more
/**
* @type import('hardhat/config').HardhatUserConfig
*/
module.exports = {
solidity: {
compilers: [
{
version: "0.5.17",
settings: {
optimizer: {
enabled: true,
runs: 100,
},
},
},
{
version: "0.8.9",
settings: {
optimizer: {
enabled: true,
runs: 25,
},
},
},
{
version: "0.8.17",
settings: {
optimizer: {
enabled: true,
runs: 25,
},
},
},
],
},
networks: {
hardhat: {
gasPrice: 100000000000, // 100 gwei
initialBaseFeePerGas: 0,
},
mainnet: {
url: MAINNET_JSON_RPC_PROVIDER_URL,
accounts: [`0x${MAINNET_PRIVATE_KEY}`],
gasPrice: "auto",
gasMultiplier: 1.5,
},
goerli: {
url: GOERLI_JSON_RPC_PROVIDER_URL,
accounts: [`0x${TESTNET_PRIVATE_KEY}`],
gasPrice: "auto",
gasMultiplier: 1.5,
},
coverage: {
url: "http://localhost:8545",
},
},
etherscan: {
apiKey: ETHERSCAN_API_KEY,
},
contractSizer: {
alphaSort: true,
runOnCompile: false,
disambiguatePaths: false,
},
docgen: {
path: "./docs",
clear: true,
runOnCompile: false,
except: [
`^contracts/interfaces/0.5.x/`,
`^contracts/interfaces/0.8.x/IManifold.sol`,
`^contracts/interfaces/0.8.x/IBonusContract.sol`,
`^contracts/libs/0.5.x/`,
`^contracts/minter-suite/Minters/.*V0.sol`,
`^contracts/mock`,
`^contracts/PBAB\\+Collabs/.*/.*.sol`,
`^contracts/BasicRandomizer.sol`,
`^contracts/BasicRandomizerV2.sol`,
],
},
gasReporter: {
currency: "USD",
gasPrice: 100,
enabled: true,
coinmarketcap: process.env.COINMARKETCAP_API_KEY,
},
mocha: {
timeout: 100000,
},
};