appforge_cli 0.1.3 copy "appforge_cli: ^0.1.3" to clipboard
appforge_cli: ^0.1.3 copied to clipboard

A powerful CLI to generate production-ready Flutter apps with Firebase, localization, Docker, and modular architecture.

πŸš€ AppForge CLI #

A powerful command-line tool to generate production-ready Flutter applications with pre-configured architecture, authentication, theming, and Firebase integration.

Dart Flutter Firebase

AppForge CLI Demo
πŸ‘† 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 configure setup

🧩 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 appforge command is not found, make sure Dart's global bin directory is in your PATH
  • Run dart pub global list to verify appforge_cli is activated
  • Restart your terminal after installation

πŸš€ Quick Start #

Interactive Mode #

appforge create

Follow the prompts to configure your app:

  1. Project Name - Enter your app name
  2. State Management - Choose between Provider, Riverpod, or Bloc
  3. Theme Color - Select from 5 beautiful themes
  4. Authentication Type - Pick your auth method
  5. 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 #

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.

  1. Fork the repository
  2. Create your feature branch (git checkout -b feature/AmazingFeature)
  3. Commit your changes (git commit -m 'Add some AmazingFeature')
  4. Push to the branch (git push origin feature/AmazingFeature)
  5. 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 #

20
likes
160
points
114
downloads

Publisher

verified publisherajaychikshetty.dev

Weekly Downloads

A powerful CLI to generate production-ready Flutter apps with Firebase, localization, Docker, and modular architecture.

Repository (GitHub)
View/report issues

Topics

#cli #flutter #generator #firebase #scaffold

Documentation

Documentation
API reference

License

MIT (license)

Dependencies

args, http, interact, mason_logger, meta, path, recase, watcher, yaml

More

Packages that depend on appforge_cli