cmd 1.0.1
cmd: ^1.0.1 copied to clipboard
A comprehensive command line toolkit for Flutter developers with interactive scripts, app signing utilities, performance testing, and platform-specific tools. Includes a modern dialer interface for ea [...]
Flutter, a mobile development UI kit managed by Google comes with the handy CLI (Command Line Interface). It lets you do the same tasks that you perform using IDE. CMD package helps you quickly running the common CLI commands that are used in almost all Flutter projects by running pre-written scripts. Flutter developers find it difficult to type commands again and again and sometimes you need to run a series of commands one after another. This is where CMD package is helpful. Flutter's cmd package helps developers to save time by running scripts for performing the below operations:
✨ Features #
🎯 Interactive Dialer Interface #
- Modern terminal-based menu system
- Easy navigation between script categories
- Color-coded interface for better UX
🏥 Environment & Doctor #
- flutter doctor - Advanced environment checking
- Channel management and version control
- Configuration management
🏃 Run & Debug #
- flutter run - Enhanced run commands
- Device selection and management
- Flavor and architecture support
- Performance monitoring options
🔨 Build & Deploy #
- flutter build - Cross-platform building
- firebase deploy - Firebase deployment
- Automated build pipelines
- Size analysis and optimization
🔐 App Signing #
- NEW! Android app signing - Complete Android signing workflow
- NEW! iOS app signing - iOS provisioning and certificates
- Keystore management and security
🧪 Testing & Analysis #
- NEW! Comprehensive testing - Unit, widget, integration tests
- NEW! Performance testing - Memory, CPU, startup profiling
- Code analysis and formatting
- Coverage reporting
🧹 Maintenance #
- flutter clean - Deep cleaning utilities
- flutter pub - Package management
- Cache management and optimization
🔧 Setup & Tools #
- NEW! Project setup - Quick project initialization
- State management setup (Provider, Bloc, Riverpod)
- Firebase integration
- Environment configuration
🖥️ Platform-Specific Tools #
- NEW! macOS utilities - Xcode, CocoaPods, Simulator management
- NEW! Windows utilities - Visual Studio, MSBuild, package management
☁️ Cloud & Deploy #
- firebase deploy - Firebase hosting deployment
- gsutil cors - Google Cloud Storage configuration
Installation #
Add cmd as dev_dependency by running the command below:
flutter pub add -d cmd
OR
Add cmd this in your pubspec.yaml
:
dev_dependencies:
cmd:
Run the following commands below to install cmd:
flutter pub get
dart run cmd:install
In your project root directory you will find a folder cmd that contains all available scripts.
├── project
│ ├── cmd
│ │ ├── dialer.sh # 🎯 Interactive main menu
│ │ ├── doctor.sh # 🏥 Environment checking
│ │ ├── run.sh # 🏃 Run & debug utilities
│ │ ├── build.sh # 🔨 Build for all platforms
│ │ ├── clean.sh # 🧹 Deep cleaning
│ │ ├── pub.sh # 📦 Package management
│ │ ├── android_signing.sh # 🔐 Android signing
│ │ ├── ios_signing.sh # 🍎 iOS signing
│ │ ├── testing.sh # 🧪 Testing & analysis
│ │ ├── performance.sh # ⚡ Performance testing
│ │ ├── setup.sh # 🔧 Project setup
│ │ ├── deploy.sh # 🚀 Firebase deployment
│ │ ├── cors_gcs.sh # ☁️ Google Cloud Storage
│ │ ├── macos_utils.sh # 🍎 macOS utilities
│ │ └── windows_utils.sh # 🪟 Windows utilities
Usage #
🎯 Interactive Dialer (Recommended) #
Navigate to your project's cmd directory and run the main dialer:
cd cmd
./dialer.sh
The dialer provides an intuitive menu system with categories:
- 🏥 Environment & Doctor
- 🏃 Run & Debug
- 🔨 Build & Deploy
- 🧹 Clean & Maintenance
- 📦 Package Management
- 🔐 App Signing
- 🧪 Testing & Analysis
- ⚡ Performance
- 🔧 Setup & Tools
- ☁️ Cloud & Deploy
📱 Individual Scripts #
You can also run individual scripts directly:
# Make scripts executable (first time only)
chmod +x *.sh
# Run specific scripts
./doctor.sh # Environment check
./build.sh # Build for platforms
./testing.sh # Run tests
./android_signing.sh # Sign Android apps
./setup.sh # Setup new projects
Usage in VS Code 🧑🏻💻 #
- Install Code Runner Extension
- Right click on Script you want to execute and select
Run Code
- Alternatively use these short keys Ctrl + Alt + N when the script is opened.
What's New in v1.0.0 🎉 #
🎯 Interactive Dialer Interface #
- Modern terminal-based navigation
- Color-coded menus and feedback
- Intuitive categorization
🔐 Complete App Signing Solution #
- Android keystore creation and management
- iOS provisioning and certificate handling
- Automated signing configuration
🧪 Comprehensive Testing Suite #
- Unit, widget, and integration testing
- Performance profiling and analysis
- Code coverage reporting
- Continuous testing with file watching
⚡ Performance Testing Tools #
- Memory and CPU profiling
- Startup performance analysis
- Build size optimization
- Frame rate monitoring
🔧 Advanced Setup Utilities #
- Project templates and scaffolding
- State management setup
- Firebase integration
- Environment configuration
🖥️ Platform-Specific Tools #
- macOS: Xcode, CocoaPods, Simulator management
- Windows: Visual Studio, MSBuild, package management
- Cross-platform compatibility
🚀 Enhanced Build System #
- Interactive build options
- Multi-platform builds
- Build size analysis
- Export management
Contribution 💙 #
You are warmly welcome for contributing cmd package. You may add single line scripts or batch scripts such as cmd/build.sh
. Checkout this contribution guide.
Open Source Contributor from Punjab, Pakistan 🇵🇰