forked from Charged-Particles/erc721i
-
Notifications
You must be signed in to change notification settings - Fork 0
/
hardhat.config.js
96 lines (93 loc) · 2.08 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
require('dotenv').config();
require("@nomiclabs/hardhat-etherscan");
require("@nomiclabs/hardhat-waffle");
require("@nomiclabs/hardhat-ethers");
require("hardhat-deploy");
require("hardhat-gas-reporter");
require("hardhat-abi-exporter");
require("solidity-coverage");
const mnemonic = process.env.WALLET_MNEMONIC;
const optimizerEnabled = process.env.OPTIMIZER_ENABLED === 'true';
module.exports = {
solidity: {
compilers: [
{
version: "0.8.4",
settings: {
optimizer: {
enabled: optimizerEnabled,
runs: 200,
},
},
evmVersion: "istanbul",
},
],
},
paths: {
sources: "./contracts",
tests: "./test",
cache: "./cache",
artifacts: "./build/contracts",
deploy: "./deploy",
deployments: "./deployments",
},
networks: {
hardhat: {
blockGasLimit: 200000000,
allowUnlimitedContractSize: true,
gasPrice: 1e9,
},
goerli: {
url: `https://eth-goerli.alchemyapi.io/v2/${process.env.ALCHEMY_GOERLI_APIKEY}`,
gasPrice: 1e9,
accounts: {
mnemonic,
initialIndex: 0,
count: 10,
},
},
rinkeby: {
url: `https://eth-rinkeby.alchemyapi.io/v2/${process.env.ALCHEMY_RINKEBY_APIKEY}`,
gasPrice: 1e9,
accounts: {
mnemonic,
initialIndex: 0,
count: 10,
},
},
mumbai: {
url: `https://matic-mumbai.chainstacklabs.com/`,
gasPrice: 10e9,
accounts: {
mnemonic,
initialIndex: 0,
count: 10,
},
chainId: 80001,
},
},
etherscan: {
apiKey: {
goerli: process.env.ETHERSCAN_APIKEY,
polygonMumbai: process.env.POLYGONSCAN_APIKEY,
},
},
gasReporter: {
enabled: process.env.REPORT_GAS !== undefined,
gasPrice: 1,
currency: "USD",
},
abiExporter: {
path: "./abis",
runOnCompile: true,
clear: true,
flat: true,
only: ["DemoNFT", "ERC721i"],
},
namedAccounts: {
owner: { default: 0 },
user1: { default: 1 },
user2: { default: 2 },
user3: { default: 3 },
},
};