Skip to content

Commit 34d9cb0

Browse files
committed
feat: initial commit
1 parent 83a09ab commit 34d9cb0

11,770 files changed

Lines changed: 1387489 additions & 86 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/workflows/comment.yml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
name: PR Comment
2+
3+
on:
4+
workflow_run:
5+
workflows: [Test]
6+
types:
7+
- completed
8+
9+
jobs:
10+
comment:
11+
uses: bgd-labs/github-workflows/.github/workflows/comment.yml@main
12+
secrets:
13+
READ_ONLY_PAT: ${{ secrets.READ_ONLY_PAT }}

.github/workflows/test.yml

Lines changed: 41 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,45 +1,59 @@
1-
name: CI
1+
name: Test
2+
3+
concurrency:
4+
group: ${{ github.head_ref || github.run_id }}
5+
cancel-in-progress: true
26

37
on:
4-
push:
58
pull_request:
6-
workflow_dispatch:
7-
8-
env:
9-
FOUNDRY_PROFILE: ci
9+
push:
10+
branches:
11+
- main
1012

1113
jobs:
12-
check:
13-
strategy:
14-
fail-fast: true
14+
lint:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v4
18+
19+
- name: Run Foundry setup
20+
uses: bgd-labs/github-workflows/.github/actions/foundry-setup@main
21+
22+
- name: Enforce linting
23+
run: forge fmt --check
1524

16-
name: Foundry project
25+
test-sol:
26+
name: Foundry build n test
1727
runs-on: ubuntu-latest
1828
steps:
1929
- uses: actions/checkout@v4
2030
with:
2131
submodules: recursive
2232

23-
- name: Install Foundry
24-
uses: foundry-rs/foundry-toolchain@v1
33+
- uses: bgd-labs/action-rpc-env@main
2534
with:
26-
version: nightly
35+
ALCHEMY_API_KEY: ${{ secrets.ALCHEMY_API_KEY }}
2736

28-
- name: Show Forge version
29-
run: |
30-
forge --version
37+
# we simply use foundry zk for all jobs in this repo
38+
- name: Run Foundry setup
39+
uses: bgd-labs/github-workflows/.github/actions/foundry-setup@main
3140

32-
- name: Run Forge fmt
33-
run: |
34-
forge fmt --check
35-
id: fmt
41+
- name: Run Forge tests
42+
id: test
43+
uses: bgd-labs/github-workflows/.github/actions/foundry-test@main
3644

37-
- name: Run Forge build
38-
run: |
39-
forge build --sizes
40-
id: build
45+
- name: Run Gas report
46+
uses: bgd-labs/github-workflows/.github/actions/foundry-gas-report@main
4147

42-
- name: Run Forge tests
48+
- name: Run Lcov report
49+
uses: bgd-labs/github-workflows/.github/actions/foundry-lcov-report@main
50+
51+
- name: Store artifact
52+
uses: bgd-labs/github-workflows/.github/actions/comment-artifact@main
53+
54+
# we let failing tests pass so we can log them in the comment, still we want the ci to fail
55+
- name: Post test
56+
if: ${{ steps.test.outputs.testStatus != 0 || steps.zktest.outputs.testStatus != 0 }}
4357
run: |
44-
forge test -vvv
45-
id: test
58+
echo "tests failed"
59+
exit 1

.gitmodules

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
11
[submodule "lib/forge-std"]
22
path = lib/forge-std
33
url = https://github.com/foundry-rs/forge-std
4+
[submodule "lib/aave-helpers"]
5+
path = lib/aave-helpers
6+
url = https://github.com/bgd-labs/aave-helpers
7+
[submodule "lib/aave-v3-origin-private"]
8+
path = lib/aave-v3-origin-private
9+
url = https://github.com/bgd-labs/aave-v3-origin-private
10+
branch = v3.4.0

.zed/settings.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
// Folder-specific settings
2+
//
3+
// For a full list of overridable settings, and general information on folder-specific settings,
4+
// see the documentation: https://zed.dev/docs/configuring-zed#settings-files
5+
{
6+
"languages": {
7+
"Solidity": {
8+
"formatter": {
9+
"external": {
10+
"command": "forge",
11+
"arguments": ["fmt", "--raw", "-"]
12+
}
13+
}
14+
}
15+
}
16+
}
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
## Reserve changes
2+
3+
### Reserves altered
4+
5+
#### GHO ([0x40D16FC0246aD3160Ccc09B8D0D3A2cD28aE6C2f](https://etherscan.io/address/0x40D16FC0246aD3160Ccc09B8D0D3A2cD28aE6C2f))
6+
7+
| description | value before | value after |
8+
| --- | --- | --- |
9+
| supplyCap | 0 GHO | 1 GHO |
10+
| reserveFactor | 0 % [0] | 100 % [10000] |
11+
| aTokenImpl | [0x2f32A274e02FA356423CE5e97a8e3155c1Ac396b](https://etherscan.io/address/0x2f32A274e02FA356423CE5e97a8e3155c1Ac396b) | [0x2e234DAe75C793f67A35089C9d99245E1C58470b](https://etherscan.io/address/0x2e234DAe75C793f67A35089C9d99245E1C58470b) |
12+
| variableDebtTokenImpl | [0x20Cb2f303EDe313e2Cc44549Ad8653a5E8c0050e](https://etherscan.io/address/0x20Cb2f303EDe313e2Cc44549Ad8653a5E8c0050e) | [0xF62849F9A0B5Bf2913b396098F7c7019b51A820a](https://etherscan.io/address/0xF62849F9A0B5Bf2913b396098F7c7019b51A820a) |
13+
| aTokenName | Aave Ethereum GHO | hello |
14+
| aTokenSymbol | aEthGHO | yay |
15+
| variableDebtTokenName | Aave Ethereum Variable Debt GHO | hello |
16+
| variableDebtTokenSymbol | variableDebtEthGHO | yay |
17+
18+
19+
## Raw diff
20+
21+
```json
22+
{
23+
"poolConfig": {
24+
"poolImpl": {
25+
"from": "0xeF434E4573b90b6ECd4a00f4888381e4D0CC5Ccd",
26+
"to": "0x5615dEB798BB3E4dFa0139dFa1b3D433Cc23b72f"
27+
}
28+
},
29+
"reserves": {
30+
"0x40D16FC0246aD3160Ccc09B8D0D3A2cD28aE6C2f": {
31+
"aTokenImpl": {
32+
"from": "0x2f32A274e02FA356423CE5e97a8e3155c1Ac396b",
33+
"to": "0x2e234DAe75C793f67A35089C9d99245E1C58470b"
34+
},
35+
"aTokenName": {
36+
"from": "Aave Ethereum GHO",
37+
"to": "hello"
38+
},
39+
"aTokenSymbol": {
40+
"from": "aEthGHO",
41+
"to": "yay"
42+
},
43+
"reserveFactor": {
44+
"from": 0,
45+
"to": 10000
46+
},
47+
"supplyCap": {
48+
"from": 0,
49+
"to": 1
50+
},
51+
"variableDebtTokenImpl": {
52+
"from": "0x20Cb2f303EDe313e2Cc44549Ad8653a5E8c0050e",
53+
"to": "0xF62849F9A0B5Bf2913b396098F7c7019b51A820a"
54+
},
55+
"variableDebtTokenName": {
56+
"from": "Aave Ethereum Variable Debt GHO",
57+
"to": "hello"
58+
},
59+
"variableDebtTokenSymbol": {
60+
"from": "variableDebtEthGHO",
61+
"to": "yay"
62+
}
63+
}
64+
}
65+
}
66+
```

foundry.toml

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,37 @@
22
src = "src"
33
out = "out"
44
libs = ["lib"]
5+
fs_permissions = [{ access = "write", path = "./reports" }]
6+
ffi = true
57

6-
# See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options
8+
[rpc_endpoints]
9+
mainnet = "${RPC_MAINNET}"
10+
polygon = "${RPC_POLYGON}"
11+
polygon_amoy = "${RPC_POLYGON_AMOY}"
12+
avalanche = "${RPC_AVALANCHE}"
13+
avalanche_fuji = "${RPC_AVALANCHE_FUJI}"
14+
arbitrum = "${RPC_ARBITRUM}"
15+
arbitrum_sepolia = "${RPC_ARBITRUM_SEPOLIA}"
16+
fantom = "${RPC_FANTOM}"
17+
fantom_testnet = "${RPC_FANTOM_TESTNET}"
18+
optimism = "${RPC_OPTIMISM}"
19+
optimism_sepolia = "${RPC_OPTIMISM_SEPOLIA}"
20+
harmony = "${RPC_HARMONY}"
21+
sepolia = "${RPC_SEPOLIA}"
22+
scroll = "${RPC_SCROLL}"
23+
scroll_sepolia = "${RPC_SCROLL_SEPOLIA}"
24+
metis = "${RPC_METIS}"
25+
base = "${RPC_BASE}"
26+
base_sepolia = "${RPC_BASE_SEPOLIA}"
27+
bnb = "${RPC_BNB}"
28+
gnosis = "${RPC_GNOSIS}"
29+
zkEVM = "${RPC_ZKEVM}"
30+
celo = "${RPC_CELO}"
31+
zksync = "${RPC_ZKSYNC}"
32+
33+
[etherscan]
34+
mainnet = { key = "${ETHERSCAN_API_KEY_MAINNET}", chain = 1 }
35+
36+
37+
[fmt]
38+
tab_width = 2

lib/aave-helpers

Submodule aave-helpers added at c7a5bf0

lib/aave-v3-origin-private

Submodule aave-v3-origin-private added at 9ba595b

node_modules/.bin/aave-cli

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)