Skip to content

Commit ce02067

Browse files
committed
docs: update README to reflect Merkle Airdrop system features and usage instructions
1 parent 25140cc commit ce02067

File tree

1 file changed

+36
-42
lines changed

1 file changed

+36
-42
lines changed

README.md

Lines changed: 36 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,66 +1,60 @@
1-
## Foundry
1+
# Merkle Airdrop System
22

3-
**Foundry is a blazing fast, portable and modular toolkit for Ethereum application development written in Rust.**
3+
The Merkle Airdrop system enables the distribution of tokens via airdrops in a secure and gas-efficient manner using Merkle proofs to verify claims. This repository contains the smart contracts, testing suite, and deployment scripts necessary for setting up and managing a Merkle Airdrop.
44

5-
Foundry consists of:
5+
## Features
66

7-
- **Forge**: Ethereum testing framework (like Truffle, Hardhat and DappTools).
8-
- **Cast**: Swiss army knife for interacting with EVM smart contracts, sending transactions and getting chain data.
9-
- **Anvil**: Local Ethereum node, akin to Ganache, Hardhat Network.
10-
- **Chisel**: Fast, utilitarian, and verbose solidity REPL.
7+
- **Secure Token Distribution**: Uses Merkle proofs to ensure that airdrops are claimed only by eligible addresses.
8+
- **Gas Efficiency**: Reduces the gas cost by allowing users to prove their token claim without the need for on-chain storage of all possible claimants.
9+
- **EIP712 Signing**: Implements EIP712 for secure and verifiable signatures.
10+
- **Comprehensive Tests**: Includes a full suite of tests to ensure functionality and robustness.
11+
- **Script Automation**: Scripts to generate airdrop input data and Merkle proofs for deployment.
1112

12-
## Documentation
13+
## Prerequisites
1314

14-
https://book.getfoundry.sh/
15+
Before you begin, ensure you have the following installed:
1516

16-
## Usage
17-
18-
### Build
17+
- [Foundry](https://book.getfoundry.sh/getting-started/installation.html) for Solidity testing and deployment
1918

20-
```shell
21-
$ forge build
22-
```
19+
## Installation
2320

24-
### Test
21+
Clone the repository and install dependencies:
2522

26-
```shell
27-
$ forge test
23+
```bash
24+
git clone https://your-repository-url.git
25+
cd merkle-airdrop-system
26+
forge install
2827
```
2928

30-
### Format
29+
## Usage
3130

32-
```shell
33-
$ forge fmt
34-
```
31+
### Generating Merkle Proofs
3532

36-
### Gas Snapshots
33+
Generate input data and Merkle proofs by running:
3734

38-
```shell
39-
$ forge snapshot
35+
```bash
36+
forge script script/GenerateInput.s.sol
37+
forge script script/MakeMerkle.s.sol
4038
```
4139

42-
### Anvil
40+
### Running Tests
4341

44-
```shell
45-
$ anvil
42+
Execute the tests with Foundry:
43+
44+
```bash
45+
forge test
4646
```
4747

48-
### Deploy
48+
## Smart Contracts
4949

50-
```shell
51-
$ forge script script/Counter.s.sol:CounterScript --rpc-url <your_rpc_url> --private-key <your_private_key>
52-
```
50+
- **MerkleAirdrop.sol**: Main contract for handling the airdrop.
51+
- **MockToken.sol**: Mock ERC20 token for testing purposes.
5352

54-
### Cast
53+
## Scripts
5554

56-
```shell
57-
$ cast <subcommand>
58-
```
55+
- **GenerateInput.s.sol**: Generates the input data for the Merkle tree.
56+
- **MakeMerkle.s.sol**: Generates the Merkle tree root and proofs from the input data.
5957

60-
### Help
58+
## License
6159

62-
```shell
63-
$ forge --help
64-
$ anvil --help
65-
$ cast --help
66-
```
60+
Distributed under the MIT License. See `LICENSE` for more information.

0 commit comments

Comments
 (0)