Flarch is a powerful command-line interface (CLI) tool designed to simplify and streamline Flutter project development. It automates the creation of clean architecture folder structures, manages features, and configures essential project components with ease.
- Interactive & Non-Interactive Modes: Initialize Flutter projects with comprehensive setup
- Automated Configuration: Set up assets, themes, routing, networking, storage, and utilities in one command
- Clean Architecture: Full support for Clean Architecture patterns
- MVC & MVVM: Support for MVC and MVVM architectures
- State Management: Integration with Bloc, GetX, and Provider
- Create Features: Generate complete feature structures with a single command
- List Features: View all features in your project
- Remove Features: Safely delete features with all associated files
- Rename Features: Rename features while maintaining structure
- Assets Setup: Configure assets folder structure
- Theme Configuration: Set up light/dark themes
- Router Setup: Configure GoRouter for navigation
- Storage Setup: Configure local storage (Hive, SharedPreferences, ObjectBox, Isar, Drift)
- Network Setup: Configure Dio client with connectivity checking
- Utils Setup: Create constants, API endpoints, and logger utilities
- Clean pubspec.yaml: Remove unnecessary comments
- Package ID Management: Replace package IDs across the project
- App Name Management: Change app display names
- Health Check: Analyze project health and get recommendations
dart pub global activate flarchMake sure you have Dart SDK installed and pub cache bin is in your PATH.
# Interactive mode (asks questions)
flarch init
# Non-interactive mode (all options enabled)
flarch init my_app# Interactive mode
flarch "FeatureName"
# With architecture
flarch "FeatureName" --clean
flarch "FeatureName" --mvc
flarch "FeatureName" --mvvm
# With state management
flarch "FeatureName" -sm "Name" -bloc
flarch "FeatureName" -sm "Name" -getx# Setup assets
flarch config assets
# Setup theme
flarch config theme
# Setup router
flarch config router
# Setup storage
flarch config storage
# Setup network (via init)
flarch initflarch init # Interactive mode
flarch init my_app # Non-interactive mode (all options enabled)flarch list # List all features
flarch tree # Show project directory tree
flarch rm FeatureName # Remove a feature
flarch rename OldName NewName # Rename a featureflarch config assets # Setup assets folder structure
flarch config main # Clean main.dart and create app.dart
flarch config theme # Setup theme configuration
flarch config router # Setup GoRouter configuration
flarch config storage # Setup local storage
flarch config package <id> # Replace package ID
flarch config name "App Name" # Change app display nameflarch clean pubspec # Clean comments from pubspec.yaml
flarch health # Check project healthflarch "FeatureName" --clean
flarch "FeatureName" -u "UseCaseName" # Create use case
flarch "FeatureName" -m "ModelName" # Create model/entity
flarch "FeatureName" -r "RepositoryName" # Create repository
flarch "FeatureName" -d "DataSourceName" # Create data sourceflarch "FeatureName" --mvcflarch "FeatureName" --mvvmflarch "FeatureName" -sm "Name" -bloc # Bloc state management
flarch "FeatureName" -sm "Name" -getx # GetX state management
flarch "FeatureName" -sm "Name" -provider # Provider state managementFor detailed documentation, run:
flarch --helpContributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/NewFeature) - Commit your changes (
git commit -m 'Add some NewFeature') - Push to the branch (
git push origin feature/NewFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
Rakibur Rahman
- GitHub: rakibur557
- Linked-in: rakibur557
- Project: flarch_cli
- Inspired by clean architecture principles
- Built with β€οΈ for the Flutter community
Check your project's health and get recommendations:
flarch healthThis will analyze your project structure, dependencies, configuration, and best practices, providing actionable recommendations.
Made with β€οΈ for Flutter developers