Skip to content

Commit e14847c

Browse files
committed
Merge dev into main
2 parents f1969b5 + 05c70da commit e14847c

22 files changed

Lines changed: 354 additions & 0 deletions

.github/workflows/.github/workflows/ci.yml

Whitespace-only changes.

.github/workflows/test.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: CI
2+
3+
permissions: {}
4+
5+
on:
6+
push:
7+
pull_request:
8+
workflow_dispatch:
9+
10+
env:
11+
FOUNDRY_PROFILE: ci
12+
13+
jobs:
14+
check:
15+
name: Foundry project
16+
runs-on: ubuntu-latest
17+
permissions:
18+
contents: read
19+
steps:
20+
- uses: actions/checkout@v5
21+
with:
22+
persist-credentials: false
23+
submodules: recursive
24+
25+
- name: Install Foundry
26+
uses: foundry-rs/foundry-toolchain@v1
27+
28+
- name: Show Forge version
29+
run: forge --version
30+
31+
- name: Run Forge fmt
32+
run: forge fmt --check
33+
34+
- name: Run Forge build
35+
run: forge build --sizes
36+
37+
- name: Run Forge tests
38+
run: forge test -vvv

.gitignore

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Compiler files
2+
cache/
3+
out/
4+
5+
# Ignores development broadcast logs
6+
!/broadcast
7+
/broadcast/*/31337/
8+
/broadcast/**/dry-run/
9+
10+
# Docs
11+
docs/
12+
13+
# Dotenv file
14+
.env

.gitmodules

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
[submodule "lib/forge-std"]
2+
path = lib/forge-std
3+
url = https://github.com/foundry-rs/forge-std
4+
[submodule "lib/solady"]
5+
path = lib/solady
6+
url = https://github.com/vectorized/solady
7+
[submodule "lib/prb-test"]
8+
path = lib/prb-test
9+
url = https://github.com/PaulRBerg/prb-test
10+
[submodule "lib/openzeppelin-contracts"]
11+
path = lib/openzeppelin-contracts
12+
url = https://github.com/OpenZeppelin/openzeppelin-contracts

README.md

Lines changed: 69 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
<<<<<<< HEAD
12
# CodesenSys ERC20 Implementation (Foundry | Solady)
23

34
A production-grade, security-first ERC20 token implementation built by **CodesenSys** using **Foundry**.
@@ -163,3 +164,71 @@ Governance voting power
163164
Bridging adapters
164165
Upgradeable proxies
165166
Without modifying the core accounting engine.
167+
=======
168+
## Foundry
169+
170+
**Foundry is a blazing fast, portable and modular toolkit for Ethereum application development written in Rust.**
171+
172+
Foundry consists of:
173+
174+
- **Forge**: Ethereum testing framework (like Truffle, Hardhat and DappTools).
175+
- **Cast**: Swiss army knife for interacting with EVM smart contracts, sending transactions and getting chain data.
176+
- **Anvil**: Local Ethereum node, akin to Ganache, Hardhat Network.
177+
- **Chisel**: Fast, utilitarian, and verbose solidity REPL.
178+
179+
## Documentation
180+
181+
https://book.getfoundry.sh/
182+
183+
## Usage
184+
185+
### Build
186+
187+
```shell
188+
$ forge build
189+
```
190+
191+
### Test
192+
193+
```shell
194+
$ forge test
195+
```
196+
197+
### Format
198+
199+
```shell
200+
$ forge fmt
201+
```
202+
203+
### Gas Snapshots
204+
205+
```shell
206+
$ forge snapshot
207+
```
208+
209+
### Anvil
210+
211+
```shell
212+
$ anvil
213+
```
214+
215+
### Deploy
216+
217+
```shell
218+
$ forge script script/Counter.s.sol:CounterScript --rpc-url <your_rpc_url> --private-key <your_private_key>
219+
```
220+
221+
### Cast
222+
223+
```shell
224+
$ cast <subcommand>
225+
```
226+
227+
### Help
228+
229+
```shell
230+
$ forge --help
231+
$ anvil --help
232+
$ cast --help
233+
```
234+
>>>>>>> dev

foundry.lock

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
{
2+
"lib/forge-std": {
3+
"tag": {
4+
"name": "v1.14.0",
5+
"rev": "1801b0541f4fda118a10798fd3486bb7051c5dd6"
6+
}
7+
},
8+
"lib/openzeppelin-contracts": {
9+
"tag": {
10+
"name": "v5.5.0",
11+
"rev": "fcbae5394ae8ad52d8e580a3477db99814b9d565"
12+
}
13+
},
14+
"lib/prb-test": {
15+
"tag": {
16+
"name": "v0.6.5",
17+
"rev": "2ece8755d9afe7d66440ef9ca19b8a9dab40164b"
18+
}
19+
},
20+
"lib/solady": {
21+
"tag": {
22+
"name": "v0.1.26",
23+
"rev": "acd959aa4bd04720d640bf4e6a5c71037510cc4b"
24+
}
25+
}
26+
}

foundry.toml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
[profile.default]
2+
src = "src"
3+
out = "out"
4+
libs = ["lib"]
5+
remappings = [
6+
"forge-std/=lib/forge-std/src/",
7+
"solady/=lib/solady/src/",
8+
"@solady-utils/=lib/solady/src/utils/",
9+
]
10+
11+
[rpc_endpoints]
12+
sepolia = "${SEPOLIA_RPC_URL}"
13+
14+
[etherscan]
15+
sepolia = { key = "${ETHERSCAN_API_KEY}" }
16+
17+
# See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options

lib/forge-std

Submodule forge-std added at 1801b05

lib/openzeppelin-contracts

Submodule openzeppelin-contracts added at fcbae53

lib/prb-test

Submodule prb-test added at 2ece875

0 commit comments

Comments
 (0)