π AppForge CLI
A powerful command-line tool to generate production-ready Flutter applications with pre-configured architecture, authentication, theming, and Firebase integration.
π Click to watch the demo video
β¨ Features
π¨ Beautiful Themes
- 5 pre-built color schemes (Blue, Green, Coffee, Purple, Orange)
- Complete light & dark mode support
- Material 3 design system
- Responsive layouts for phones and tablets
π Multiple Authentication Methods
- Email & Password - Traditional auth with validation
- Username & Password - Username-based authentication
- Phone & OTP - SMS verification with 6-digit OTP
- Social Auth - Google & Apple Sign-In
- All Methods - Unified auth interface with all options
π₯ Modular Firebase Integration
- Authentication - Sign up, sign in, profile management
- Cloud Firestore - Complete CRUD operations with real-time streams
- Cloud Storage - File upload/download with progress tracking
- Cloud Messaging - Push notifications with FCM
- Automatic
flutterfire configuresetup
π§© 12+ Reusable Widgets
- Custom App Bar & Bottom Navigation
- Loading indicators (3 types)
- Info, Image, and Action Cards
- Primary, Secondary, and Icon Buttons
- Empty & Error States
- Custom Input Fields & Search
- Dialog & Snackbar Helpers
- List Tiles, Avatars, and Badges
ποΈ Clean Architecture
- Feature-based folder structure
- Separation of concerns
- Scalable and maintainable codebase
- Go Router for navigation
- State management (Provider, Riverpod, or Bloc)
π± Ready-to-Use Screens
- Splash Screen with animations
- Home Screen with stats and quick actions
- Profile Screen with settings
- Login/Signup screens (based on auth type)
- All screens are responsive and themed
οΏ½ Screenshots
οΏ½π¦ Installation
Prerequisites
- Dart SDK (>=3.5.0)
- Flutter SDK
- Firebase CLI (optional, for Firebase features)
Install from pub.flutter-io.cn
dart pub global activate appforge_cli
Or install from source
git clone https://github.com/appforge-cli/appforge_cli.git
cd appforge_cli
dart pub get
dart pub global activate --source path .
Verify Installation
After installation, verify that AppForge CLI is properly installed:
appforge --version
You should see:
appforge_cli version: 0.1.3
Or simply run:
appforge
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β β
β ββββββ βββββββ βββββββ ββββββββ βββββββ βββββββ βββββββ ββββββββ β
β βββββββββββββββββββββββββββββββββββββββββββββββββββββββββ ββββββββ β
β ββββββββββββββββββββββββββββββ βββ ββββββββββββββ ββββββββββ β
β βββββββββββββββ βββββββ ββββββ βββ ββββββββββββββ βββββββββ β
β βββ ββββββ βββ βββ ββββββββββββ ββββββββββββββββββββ β
β βββ ββββββ βββ βββ βββββββ βββ βββ βββββββ ββββββββ β
β β
β ββββββββββ βββ β
β βββββββββββ βββ β
β βββ βββ βββ β
β βββ βββ βββ β
β βββββββββββββββββββ β
β ββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
If you see this, your installation is complete! π
Troubleshooting:
- If
appforgecommand is not found, make sure Dart's global bin directory is in your PATH - Run
dart pub global listto verify appforge_cli is activated - Restart your terminal after installation
π Quick Start
Interactive Mode
appforge create
Follow the prompts to configure your app:
- Project Name - Enter your app name
- State Management - Choose between Provider, Riverpod, or Bloc
- Theme Color - Select from 5 beautiful themes
- Authentication Type - Pick your auth method
- Firebase - Enable and select Firebase modules
Non-Interactive Mode
appforge create \
--name my_awesome_app \
--org com.mycompany \
--state riverpod \
--theme blue \
--firebase
With Flags
# Short flags
appforge create -n my_app -s bloc -t coffee -f
# Full options
appforge create \
--name my_app \
--org com.example \
--state provider \
--theme purple \
--firebase \
--yes
π― Usage Examples
Example 1: E-commerce App with Firebase
appforge create
# Selections:
# Name: shop_app
# State: riverpod
# Theme: blue
# Auth: email_password
# Firebase: Yes
# - auth
# - firestore
# - storage
Generated structure:
shop_app/
βββ lib/
β βββ app/
β β βββ router/
β β βββ theme/
β βββ features/
β β βββ auth/
β β βββ home/
β β βββ profile/
β βββ shared/
β β βββ widgets/ # 12+ reusable widgets
β βββ core/
β β βββ firebase/ # Complete Firebase CRUD
β βββ main.dart
βββ pubspec.yaml
Example 2: Social Media App
appforge create -n social_app -s bloc -t purple
# Auth: all (email, username, phone, social)
# Firebase: Yes (all modules)
Example 3: Simple Utility App
appforge create -n util_app -s provider -t green
# Auth: email_password
# Firebase: No
π Generated Project Structure
your_app/
βββ lib/
β βββ app/
β β βββ router/
β β β βββ app_router.dart # Go Router configuration
β β βββ theme/
β β β βββ app_theme.dart # Light & Dark themes
β β βββ di/ # Dependency injection
β βββ features/
β β βββ app/
β β β βββ screens/
β β β βββ splash_screen.dart
β β βββ auth/
β β β βββ screens/
β β β β βββ login_screen.dart
β β β β βββ signup_screen.dart
β β β β βββ otp_verification_screen.dart
β β β βββ widgets/
β β β βββ services/
β β βββ home/
β β β βββ screens/
β β β βββ home_screen.dart
β β βββ profile/
β β βββ screens/
β β βββ profile_screen.dart
β βββ shared/
β β βββ widgets/
β β β βββ widgets.dart # Barrel file
β β β βββ custom_app_bar.dart
β β β βββ custom_bottom_nav_bar.dart
β β β βββ loading_indicators.dart
β β β βββ custom_cards.dart
β β β βββ custom_buttons.dart
β β β βββ empty_states.dart
β β β βββ custom_input_fields.dart
β β β βββ dialog_helper.dart
β β β βββ snackbar_helper.dart
β β β βββ custom_list_tiles.dart
β β β βββ custom_avatar.dart
β β β βββ custom_badge.dart
β β βββ services/
β β βββ utils/
β β βββ constants/
β βββ core/
β β βββ firebase/
β β β βββ firebase_operations.dart # Complete Firebase CRUD
β β βββ errors/
β β βββ network/
β β βββ storage/
β βββ main.dart
βββ test/
β βββ widget_test.dart
βββ pubspec.yaml
βββ README.md
π¨ Available Themes
| Theme | Primary Color | Use Case |
|---|---|---|
| π Blue | #2196F3 | Professional apps |
| π Green | #4CAF50 | Health & Fitness |
| β Coffee | #795548 | Lifestyle apps |
| π Purple | #9C27B0 | Creative apps |
| π§‘ Orange | #FF9800 | Food & Delivery |
π Authentication Types
Email & Password
await FirebaseOperations.signUpWithEmail(
email: 'user@example.com',
password: 'password123',
);
Phone & OTP
// Send OTP
context.push('/otp-verification', extra: phoneNumber);
// Verify OTP
await FirebaseOperations.verifyOTP(code: '123456');
Social Auth
await FirebaseOperations.signInWithGoogle();
await FirebaseOperations.signInWithApple();
π₯ Firebase Operations
Firestore CRUD
// Create
final docId = await FirebaseOperations.createDocument(
collection: 'users',
data: {'name': 'John', 'age': 30},
);
// Read
final data = await FirebaseOperations.readDocument(
collection: 'users',
documentId: docId,
);
// Update
await FirebaseOperations.updateDocument(
collection: 'users',
documentId: docId,
data: {'age': 31},
);
// Delete
await FirebaseOperations.deleteDocument(
collection: 'users',
documentId: docId,
);
// Real-time Stream
StreamBuilder(
stream: FirebaseOperations.streamCollection(
collection: 'messages',
orderBy: 'timestamp',
),
builder: (context, snapshot) {
// Build your UI
},
)
Storage Operations
// Upload file
final url = await FirebaseOperations.uploadFile(
file: imageFile,
path: 'users/$userId/profile.jpg',
onProgress: (progress) {
print('Upload: ${(progress * 100).toInt()}%');
},
);
// Download file
final file = await FirebaseOperations.downloadFile(
path: 'users/$userId/profile.jpg',
localPath: '/path/to/save/image.jpg',
);
// Delete file
await FirebaseOperations.deleteFile(
path: 'users/$userId/old_profile.jpg',
);
Cloud Messaging
// Initialize
await FirebaseOperations.initializeFCM();
// Get token
final token = await FirebaseOperations.getFCMToken();
// Subscribe to topic
await FirebaseOperations.subscribeToTopic(topic: 'news');
// Handle messages
FirebaseOperations.handleForegroundMessages((message) {
print('New message: ${message.notification?.title}');
});
π§© Using Reusable Widgets
Import
import 'package:your_app/shared/widgets/widgets.dart';
Examples
// Custom App Bar
CustomAppBar(
title: 'My Screen',
actions: [
IconButtonCustom(icon: Icons.search, onPressed: () {}),
],
)
// Info Card
InfoCard(
title: 'Total Sales',
value: '\$12,345',
icon: Icons.attach_money,
color: Colors.green,
)
// Primary Button
PrimaryButton(
text: 'Submit',
isLoading: isLoading,
onPressed: () {},
)
// Snackbar
SnackBarHelper.showSuccess(context, 'Saved successfully!');
// Dialog
await DialogHelper.showConfirmDialog(
context,
title: 'Delete',
message: 'Are you sure?',
);
π οΈ CLI Options
| Option | Short | Description | Values |
|---|---|---|---|
--name |
-n |
Project name | my_app |
--org |
-o |
Organization | com.example |
--state |
-s |
State management | provider, riverpod, bloc |
--theme |
-t |
Theme color | blue, green, coffee, purple, orange |
--firebase |
-f |
Include Firebase | Flag (boolean) |
--yes |
-y |
Non-interactive | Flag (boolean) |
π State Management Options
Riverpod (Recommended)
final counterProvider = StateProvider((ref) => 0);
Consumer(
builder: (context, ref, child) {
final count = ref.watch(counterProvider);
return Text('Count: $count');
},
)
Provider
ChangeNotifierProvider(
create: (_) => CounterModel(),
child: MyApp(),
)
Bloc
BlocProvider(
create: (_) => CounterBloc(),
child: MyApp(),
)
π€ Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
π License
This project is licensed under the MIT License - see the LICENSE file for details.
π Acknowledgments
- Flutter Team for the amazing framework
- Firebase for backend services
- The Dart community for excellent packages
π§ Contact
- Ajay Chikshetty β’ GitHub: https://github.com/ajaychikshetty | LinkedIn: https://www.linkedin.com/in/ajaychikshetty
- Saksham Khare β’ GitHub: https://github.com/SakshamVK | LinkedIn: https://www.linkedin.com/in/sakshamvinodkhare/
Libraries
- commands/create_command
- generators/project_generator
- templates/app_localization_template
- templates/app_readme_template
- templates/app_router_template
- templates/auth_template
- templates/chatbot_templates
- templates/docker_templates
- templates/enhanced_widgets_part2
- templates/enhanced_widgets_template
- templates/firebase_operations_template
- templates/main_template
- templates/modules_template
- templates/native_permissions
- templates/onboarding_template
- templates/pubspec_template
- templates/screen_templates
- templates/theme_template
- utils/file_utils