Make

GEXD

📝 Description

Generate various project files and components. The make command is the primary code generation tool in Gexd CLI, offering powerful scaffolding capabilities for Flutter projects with GetX and Clean Architecture patterns.


⚙️ Usage


📚 Available Subcommands

🏗️ Core Components

Description: Generate complete screen components (controller, view, binding)

Description: Generate controller files for state management

Description: Generate view files (UI components)

Description: Generate binding files for dependency injection


📊 Data Layer

Description: Generate type-safe model files from JSON sources with advanced features

Description: Generate repository files for data access layers

Description: Generate service files for business logic

Description: Generate provider files for data sources


🏛️ Architecture Components

Description: Generate entity files for domain layer

Description: Generate interface files for contracts and abstractions

Description: Generate custom exception classes

Description: Generate middleware files for request/response handling


🛠️ Utility Components

Description: Generate reusable widget components

Description: Generate utility helper classes

Description: Generate constant definition files


🎯 Command Categories

📱 UI Components

  • screen - Complete screen with controller, view, binding

  • view - UI view components

  • widget - Reusable widget components

🔧 State Management

  • controller - State controllers

  • binding - Dependency injection bindings

  • middleware - Request/response middleware

📊 Data Management

  • model - Data models with serialization

  • repository - Data access repositories

  • service - Business logic services

  • provider - Data source providers

🏗️ Architecture

  • entity - Domain entities

  • interface - Contract abstractions

  • exception - Custom exceptions

🛠️ Utilities

  • util - Helper utilities

  • constant - Application constants


🚀 Common Usage Patterns

📱 Complete Feature Generation

🏗️ Clean Architecture Setup

📊 API Integration Workflow


⚙️ Global Options

Most make subcommands support these common options:

📁 Organization

  • --on <path> - Specify subdirectory for generated files

  • --force - Force overwrite existing files without prompting

🎨 Customization

  • --type <type> - Specify component type/style

  • --template <template> - Choose generation template

  • --style <style> - Select code generation style

🔧 Features

  • --interface - Generate with interface abstraction

  • --immutable - Create immutable data structures

  • --copyWith - Add copy methods for state updates


💡 Pro Tips

🎯 Best Practices

  1. Start with Architecture: Generate entities and interfaces first

  2. Use --on for Organization: Keep related files in subdirectories

  3. Enable Interfaces: Use --interface for better testability

  4. Force During Development: Use --force for rapid iteration

🚀 Efficiency Tips

  1. Batch Generation: Generate related components together

  2. Template Reuse: Save commonly used flag combinations

  3. API-First Development: Generate models from live APIs

  4. Relationship Management: Use --relationships-in-folder for complex models

🔧 Advanced Workflows

  1. Feature-Based: Group components by feature using --on

  2. Layer-Based: Organize by architectural layers

  3. Test-Driven: Generate interfaces first for better testing

  4. Iterative: Start simple, add features with --force


For detailed documentation on each subcommand, click the links above or visit:


Generated automatically by gexd_doc

Last updated