Skip to content

Commit

Permalink
Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
RogerPodacter committed Aug 6, 2024
1 parent 12bf857 commit 2b2837d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 67 deletions.
67 changes: 1 addition & 66 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,66 +1 @@
## Foundry

**Foundry is a blazing fast, portable and modular toolkit for Ethereum application development written in Rust.**

Foundry consists of:

- **Forge**: Ethereum testing framework (like Truffle, Hardhat and DappTools).
- **Cast**: Swiss army knife for interacting with EVM smart contracts, sending transactions and getting chain data.
- **Anvil**: Local Ethereum node, akin to Ganache, Hardhat Network.
- **Chisel**: Fast, utilitarian, and verbose solidity REPL.

## Documentation

https://book.getfoundry.sh/

## Usage

### Build

```shell
$ forge build
```

### Test

```shell
$ forge test
```

### Format

```shell
$ forge fmt
```

### Gas Snapshots

```shell
$ forge snapshot
```

### Anvil

```shell
$ anvil
```

### Deploy

```shell
$ forge script script/Counter.s.sol:CounterScript --rpc-url <your_rpc_url> --private-key <your_private_key>
```

### Cast

```shell
$ cast <subcommand>
```

### Help

```shell
$ forge --help
$ anvil --help
$ cast --help
```
forge script script/Deploy.s.sol:DeployScript --broadcast --rpc-url ...
9 changes: 9 additions & 0 deletions lib/LibFacet.sol
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,15 @@ library LibFacet {
) internal {
sendFacetTransaction(abi.encodePacked(to), value, maxFeePerGas, gasLimit, data);
}

function sendFacetTransaction(
uint256 value,
uint256 maxFeePerGas,
uint256 gasLimit,
bytes memory data
) internal {
sendFacetTransaction(bytes(''), value, maxFeePerGas, gasLimit, data);
}

function sendFacetTransaction(
bytes memory to,
Expand Down
1 change: 0 additions & 1 deletion script/Deploy.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ contract DeployScript is Script {

LibFacet.sendFacetTransaction(
{
to: bytes(''),
value: 0,
maxFeePerGas: 10,
gasLimit: 500_000,
Expand Down

0 comments on commit 2b2837d

Please sign in to comment.