Developer Command
Developer utilities and helpers for EVVM contract development.
Command
./evvm developer [options]
Description
The developer command provides utilities for EVVM developers working with smart contracts. It includes tools for generating interfaces, running tests, and other development workflows.
This command is primarily intended for EVVM core developers and advanced users who need to work with contract interfaces or modify EVVM contracts.
Options
--makeInterface, -i
Generate Solidity interfaces for EVVM contracts.
- Type:
boolean - Default:
false - Usage:
./evvm developer --makeInterface
This option:
- Analyzes compiled EVVM contracts
- Extracts public/external functions
- Generates
.solinterface files - Useful for integration and testing
--runTest, -t
Run the complete test suite for EVVM contracts.
- Type:
boolean - Default:
false - Usage:
./evvm developer --runTest
This option:
- Compiles all contracts
- Runs unit tests
- Runs fuzz tests
- Generates test reports
Usage Examples
Generate Contract Interfaces
./evvm developer --makeInterface
This command will:
- Read compiled contract artifacts
- Generate interface files for all EVVM contracts
- Save interfaces to the appropriate directory
Output:
Generating contract interfaces...
✓ IEvvm.sol
✓ INameService.sol
✓ IStaking.sol
✓ IEstimator.sol
✓ ITreasury.sol
✓ IP2PSwap.sol
Interfaces generated successfully!
Use Cases
For Integration Developers
Generate interfaces to:
- Build external contracts that interact with EVVM
- Create mock contracts for testing
- Ensure type-safe contract interactions
For Core Developers
Generate interfaces to:
- Update contract interfaces after modifications
- Maintain consistency across contracts
- Document public contract APIs
Usage Examples
Interactive Mode
Run without flags for interactive menu:
./evvm developer
This shows options:
Select an action:
🭬 Generate Contract Interfaces
Run Full Test Suite
exit
Generate Contract Interfaces
./evvm developer --makeInterface
Run Tests
./evvm developer --runTest
Related Commands
Examples
Complete Development Workflow
-
Generate interfaces:
./evvm developer --makeInterface -
Deploy to local testnet:
./evvm deploy --skipInputConfig -
Test integration:
# Use generated interfaces in your test contracts
Prerequisites
Before using developer commands:
- Foundry - Required for contract compilation
- Bun - Required for CLI execution
- Compiled contracts - Run
forge buildbefore generating interfaces
Troubleshooting
Contracts Not Compiled
If interface generation fails:
Error: No compiled contracts found
Solution: Compile contracts first:
forge build
Permission Issues
If file writing fails:
Solution: Ensure you have write permissions in the project directory.
Best Practices
- Regenerate after changes: Always regenerate interfaces after modifying contracts
- Version control: Commit generated interfaces to version control
- Testing: Use generated interfaces in test contracts for type safety
- Documentation: Interfaces serve as contract API documentation