This is a simple project to demonstrate how to use the Foundry framework to build a simple crowdfunding application.
Important elements in this project are:
- the unit and integration tests
- the use of scripts for deployment as well as managing the funds of the contract
- the use of keystore based accounts using the --account parameter
The Makefile does all the heavy lifting for you. It will install all the dependencies, build the project, run the tests and deploy the contract to the specified network.
$ make build
$ make test
$ make fmt
$ make snapshot
To deploy locally
$ make deploy
To deploy to Sepolia
$ make deploy --network sepolia
To fund the contract on a local network
$ make fund
To fund the contract on Sepolia
$ make fund --network sepolia
To withdraw from the contract on a local network
$ make withdraw
To withdraw from the contract on Sepolia
$ make withdraw --network sepolia