-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'eyqs/NES-188' into eyqs/NES-186
- Loading branch information
Showing
15 changed files
with
321 additions
and
158 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
## What's new in this PR? | ||
|
||
In bullet point format, please describe what's new in this PR. | ||
|
||
## Why? | ||
|
||
What problem does this solve? | ||
Why is this important? | ||
What's the context? |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Continuous Integration | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
env: | ||
FOUNDRY_PROFILE: ci | ||
|
||
jobs: | ||
check: | ||
strategy: | ||
fail-fast: true | ||
|
||
name: Build and Test Contracts | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
with: | ||
submodules: recursive | ||
|
||
- name: Install Foundry | ||
uses: foundry-rs/foundry-toolchain@v1 | ||
with: | ||
version: nightly | ||
|
||
# - name: Run Forge build | ||
# run: | | ||
# forge --version | ||
# forge build nest --sizes | ||
# id: build | ||
|
||
- name: Run Forge format | ||
run: | | ||
forge fmt nest --check | ||
id: format | ||
|
||
# - name: Run Forge tests | ||
# run: | | ||
# forge test nest -vvv | ||
# id: test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
# Compiler files | ||
cache/ | ||
out/ | ||
|
||
# Ignores development broadcast logs | ||
!/broadcast | ||
/broadcast/*/31337/ | ||
/broadcast/*/18230/ | ||
/broadcast/**/dry-run/ | ||
|
||
# Docs | ||
docs/ | ||
|
||
# Dotenv file | ||
.env |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
## Foundry Template Setup | ||
|
||
Copy this folder to start a new Foundry project, then run the following to initialize the submodules: | ||
|
||
```bash | ||
$ forge install foundry-rs/forge-std | ||
$ forge install OpenZeppelin/openzeppelin-foundry-upgrades | ||
$ forge install OpenZeppelin/openzeppelin-contracts-upgradeable | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
[profile.default] | ||
solc = "0.8.25" | ||
evm_version = "cancun" | ||
src = "src" | ||
out = "out" | ||
libs = ["lib"] | ||
ffi = true | ||
ast = true | ||
build_info = true | ||
extra_output = ["storageLayout"] | ||
|
||
[fmt] | ||
single_line_statement_blocks = "multi" | ||
multiline_func_header = "params_first" | ||
sort_imports = true | ||
contract_new_lines = true | ||
bracket_spacing = true | ||
int_types = "long" | ||
quote_style = "double" | ||
number_underscore = "thousands" | ||
wrap_comments = true | ||
|
||
remappings = [ | ||
"@openzeppelin/contracts/=lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/", | ||
"@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/", | ||
] |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,26 @@ | ||
[profile.default] | ||
solc = "0.8.25" | ||
evm_version = "cancun" | ||
src = "src" | ||
out = "out" | ||
libs = ["lib"] | ||
ffi = true | ||
ast = true | ||
build_info = true | ||
extra_output = ["storageLayout"] | ||
|
||
# See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options | ||
[fmt] | ||
single_line_statement_blocks = "multi" | ||
multiline_func_header = "params_first" | ||
sort_imports = true | ||
contract_new_lines = true | ||
bracket_spacing = true | ||
int_types = "long" | ||
quote_style = "double" | ||
number_underscore = "thousands" | ||
wrap_comments = true | ||
|
||
remappings = [ | ||
"@openzeppelin/contracts/=lib/openzeppelin-contracts-upgradeable/lib/openzeppelin-contracts/contracts/", | ||
"@openzeppelin/contracts-upgradeable/=lib/openzeppelin-contracts-upgradeable/contracts/", | ||
] |
Submodule openzeppelin-foundry-upgrades
added at
dd9e5d
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// SPDX-License-Identifier: MIT | ||
pragma solidity ^0.8.25; | ||
|
||
import "forge-std/Script.sol"; | ||
|
||
import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; | ||
import { Upgrades } from "openzeppelin-foundry-upgrades/Upgrades.sol"; | ||
|
||
import { FakeComponentToken } from "../src/FakeComponentToken.sol"; | ||
|
||
contract DeployNestContracts is Script { | ||
|
||
address private constant ARC_ADMIN_ADDRESS = 0x1c9d94FAD4ccCd522804a955103899e0D6A4405a; | ||
address private constant USDC_ADDRESS = 0x849c25e6cCB03cdc23ba91d92440dA7bC8486be2; | ||
|
||
function run() external { | ||
vm.startBroadcast(ARC_ADMIN_ADDRESS); | ||
|
||
address fakeComponentTokenProxy = Upgrades.deployUUPSProxy( | ||
"FakeComponentToken.sol", | ||
abi.encodeCall(FakeComponentToken.initialize, (msg.sender, "Banana", "BAN", IERC20(USDC_ADDRESS), 18)) | ||
); | ||
console.log("FakeComponentToken deployed to:", fakeComponentTokenProxy); | ||
|
||
vm.stopBroadcast(); | ||
} | ||
|
||
} |
Oops, something went wrong.