Flutter Template Generator
A command-line tool to quickly generate Flutter projects from B-L Studios template with interactive setup.
Features
- ๐ Interactive CLI setup
- ๐ฑ Pre-configured for dev and prod flavors
- ๐ฅ Firebase ready structure
- ๐จ Flavorizr integration for app icons
- ๐ป IDE configuration (VS Code & Android Studio)
- ๐งน Automatic project cleanup and setup
- โจ Colored terminal output for better UX
Prerequisites
- Flutter SDK (3.35.1 or higher)
- Dart SDK (3.9.0 or higher)
- Git
Installation
Install globally using pub:
dart pub global activate ca_generator
Make sure ~/.pub-cache/bin is in your PATH.
Usage
Run the generator:
ca_generator
The tool will guide you through:
- Project Location - Where to create your project
- Project Name - Must be lowercase with underscores
- Package Name - Android package name (com.company.app format)
- IDE Choice - VS Code or Android Studio
- Confirmation - Review settings before creation
Command Line Options
ca_generator --help # Show help
ca_generator --version # Show version
What Gets Created
Your new Flutter project includes:
- โ
Two flavors:
devandprod - โ Firebase configuration structure
- โ Custom app icons setup
- โ Makefile with common commands
- โ Pre-configured project structure
- โ IDE-specific configurations
Next Steps After Creation
-
Navigate to your project:
cd /path/to/your/project -
Set up Firebase (optional):
- Generate Firebase configuration files
- Place them in the
.firebasefolder
-
Add custom app icons:
- Add your logo files to
assets/images - Run
make flavorizrto apply icons
- Add your logo files to
-
Explore available commands:
make help
Available Make Commands
make clean- Clean the projectmake pub-get- Get dependenciesmake flavorizr- Configure app icons and flavorsmake run-dev- Run development flavormake run-prod- Run production flavormake build-dev- Build development APKmake build-prod- Build production APK
Template Repository
This tool uses the template from: https://github.com/B-L-Studios/flutter-temp
Troubleshooting
Command not found
If ca_generator command is not found after installation:
-
Make sure pub cache bin is in your PATH:
export PATH="$PATH":"$HOME/.pub-cache/bin" -
Or run directly:
dart pub global run ca_generator
Prerequisites not met
Make sure you have Flutter and Git installed:
flutter doctor # Check Flutter installation
git --version # Check Git installation
Contributing
- Fork the repository
- Create your feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
License
MIT License - see LICENSE file for details.
Support
- ๐ Report Issues
- ๐ฌ Discussions
- ๐ง Support: support@blstudios.com
Made with โค๏ธ by B-L Studios