πŸƒ Nyati

pub package Dart CLI License: MIT

Nyati is a command-line interface (CLI) tool that helps you generate Flutter projects with a custom folder structure and boilerplate. It is built to save time and enforce consistency across Flutter apps.


πŸš€ Features

  • Creates a new Flutter project automatically using flutter create
  • Adds a clean, maintainable folder structure (core/, features/, widgets/)
  • Includes starter files (main.dart, app.dart, router.dart, theme.dart)
  • Automatically installs common dependencies (go_router, provider, etc.)
  • Initializes a Git repository
  • Supports future expansions (e.g., nyati add feature auth)

βš™οΈ Installation

Install globally from pub.dev:

dart pub global activate nyati

After this, the CLI command nyati will be available globally.


βš™οΈ Usage

Create a new Flutter project:

nyati my_app

Optional subcommands (if implemented):

nyati init my_app

This will generate a Flutter project with your custom folder structure and starter files.


πŸ“‚ Project Structure

Generated project structure:

my_app/
 ┣ lib/
 ┃ ┣ core/
 ┃ ┃ ┣ constants/
 ┃ ┃ ┣ routes/app_router.dart
 ┃ ┃ ┣ themes/app_theme.dart
 ┃ ┣ features/
 ┃ ┃ ┣ auth/
 ┃ ┃ ┃ ┣ data/
 ┃ ┃ ┃ ┣ domain/
 ┃ ┃ ┃ β”— presentation/
 ┃ ┃ ┣ home/
 ┃ ┃ ┃ β”— presentation/home_page.dart
 ┃ ┣ widgets/
 ┃ ┣ app.dart
 ┃ β”— main.dart
 ┣ pubspec.yaml
 ┣ README.md
 β”— .git/

▢️ Run the Project

cd my_app
flutter run

🧩 Updating Nyati

To update to the latest version:

dart pub global activate nyati

🧰 Local Development / Contributing

If you want to contribute or test changes locally:

# Clone repository
git clone https://github.com/yourusername/nyati.git
cd nyati

# Activate locally
dart pub global activate --source path .

# Test CLI
nyati demo_app

πŸ’‘ Planned Features

  • nyati add feature <name> β†’ auto-generate a new feature module
  • Colored terminal output using ansicolor
  • Configurable templates via nyati_config.yaml
  • Custom dependency injection setup

πŸ–ΌοΈ Example Output

πŸš€ Creating Flutter project "my_app"...
🧱 Applying clean architecture structure...
πŸ“¦ Adding dependencies: provider, go_router
πŸͺ„ Initializing git repository...
βœ… Project "my_app" created successfully!
πŸ‘‰ cd my_app
πŸ‘‰ flutter run

❀️ Why β€œNyati”?

In Swahili, Nyati means Buffalo β€” strong, determined, and unstoppable. This CLI aims to embody that spirit: powerful, fast, and dependable for Flutter developers.


🀝 Contributing

Contributions, issues, and feature requests are welcome! Feel free to open an issue or pull request on GitHub.


πŸ“œ License

This project is licensed under the MIT License β€” see the LICENSE file for details.


Libraries

nyati