-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathhardhat.config.js
61 lines (61 loc) · 1.82 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
require("@nomicfoundation/hardhat-toolbox");
require('@typechain/hardhat')
require('@nomicfoundation/hardhat-ethers')
require('@nomicfoundation/hardhat-chai-matchers')
const dotenv = require("dotenv")
dotenv.config()
const optimizedComilerSettings = {
version: '0.8.17',
settings: {
optimizer: { enabled: true, runs: 1000000 },
viaIR: true
}
}
let mnemonic = 'test '.repeat(11) + 'junk'
let bbMnemonic = 'confirm tell danger isolate cannon sudden ensure dog boost dynamic minute ordinary';
/** @type import('hardhat/config').HardhatUserConfig */
module.exports = {
solidity: {
compilers: [{
version: '0.8.15',
settings: {
optimizer: {
enabled: true, runs: 1000000, details: {
yulDetails: { optimizerSteps: "u", },
},
},
},
}],
overrides: {
'contracts/core/EntryPoint.sol': optimizedComilerSettings,
'contracts/samples/SimpleAccount.sol': optimizedComilerSettings
}
},
defaultNetwork: "buildbear",
networks: {
hardhat: {
},
proxy: {
url: "http://localhost:8545/",
accounts: { mnemonic },
chainId: 31337
},
buildbear: {
url: process.env.BUILDBEAR_URL,
accounts: [process.env.BUILDBEAR_PRIVATEKEY],
chainId: 11652
},
mumbai: {
url: process.env.MUMBAI_URL,
accounts: [process.env.MUMBAI_PRIVATEKEY],
chainId: 80001
}
},
typechain: {
outDir: 'src/types',
target: 'ethers-v6',
alwaysGenerateOverloads: false, // should overloads with full signatures like deposit(uint256) be generated always, even if there are no overloads?
externalArtifacts: ['externalArtifacts/*.json'], // optional array of glob patterns with external artifacts to process (for example external libs from node_modules)
dontOverrideCompile: false // defaults to false
},
};