DevKingz is a project built using Foundry, a blazing fast, portable, and modular toolkit for Ethereum application development written in Rust. That leverages the power of the ChainlinkVRF to generate provable RNG when minting a DevKingz NFT.
This project leverages Foundry's powerful tools to streamline Ethereum smart contract development and testing. It includes:
- Forge: A robust Ethereum testing framework.
- Cast: A versatile tool for interacting with EVM smart contracts, sending transactions, and retrieving chain data.
- Anvil: A local Ethereum node for development and testing.
- Chisel: A fast and verbose Solidity REPL.
The project is organized as follows:
.
├── lib/ # External libraries (e.g., Chainlink, OpenZeppelin)
├── script/ # Deployment and interaction scripts
├── src/ # Main Solidity contracts
├── test/ # Unit and integration tests
├── cache/ # Cached files for faster builds
├── foundry.toml # Foundry configuration file
├── README.md # Project documentation
For detailed documentation on Foundry, visit the Foundry Book.
Ensure you have the following installed:
- Foundry
- Node.js (for managing dependencies in
lib/
if required)
-
Clone the repository:
git clone <repository-url> cd DevKingz
-
Install dependencies:
forge install
-
Build the project:
forge build
Compile the smart contracts:
forge build
Run the test suite:
forge test
Format your Solidity code:
forge fmt
Generate gas usage snapshots:
forge snapshot
Start a local Ethereum node:
anvil
Deploy contracts using a script:
forge script script/DeployDevKingz.s.sol:DeployScript --rpc-url <your_rpc_url> --private-key <your_private_key>
Interact with contracts using Cast:
cast <subcommand>
Get help for Foundry commands:
forge --help
anvil --help
cast --help
Contributions are welcome! Please follow these steps:
- Fork the repository.
- Create a new branch for your feature or bugfix.
- Submit a pull request with a detailed description of your changes.
This project is licensed under the MIT License. See the LICENSE file for details.
- Foundry for providing the development toolkit.
- Chainlink and OpenZeppelin for their libraries.
Happy coding!