forked from ArbitrumFoundation/governance
-
Notifications
You must be signed in to change notification settings - Fork 0
/
hardhat.config.ts
41 lines (37 loc) · 906 Bytes
/
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
import { HardhatUserConfig } from "hardhat/config";
import "@nomicfoundation/hardhat-toolbox";
import "@nomicfoundation/hardhat-foundry";
import dotenv from "dotenv";
dotenv.config();
// when changing optimizer settings, make sure to also change settings in foundry.toml
const solidityProfiles = {
default: {
version: "0.8.16",
settings: {
optimizer: {
enabled: true,
runs: 20000
},
}
},
sec_council_mgmt: {
version: "0.8.16",
settings: {
optimizer: {
enabled: true,
runs: 750
},
}
}
}
const solidity = solidityProfiles[process.env.FOUNDRY_PROFILE || "default"] || solidityProfiles.default
console.log("Compiling with soldity profile:", solidity);
const config: HardhatUserConfig = {
solidity,
paths: {
sources: "./src",
tests: "./test-ts",
cache: "./cache_hardhat",
},
};
export default config;