nunomaduro/laravel-console-menu
Add interactive terminal menus to Laravel Artisan commands via a wrapper around php-school/cli-menu. Quickly build selectable option lists, ask questions, and collect input (including advanced fields like passwords), with configurable width and a clean UX.
Install the package via Composer: composer require nunomaduro/laravel-console-menu. Create interactive menu-based console commands using make:command and inject NunoMaduro\LaravelConsoleMenu\Menu into the command’s handle() method. Begin with simple single-choice menus using menu->addOption() and menu->ask().
Use the menu helper or inject the Menu class directly. Chain methods like title(), choice(), multiselect(), and confirm() to build intuitive CLI flows. Leverage Laravel 13’s console improvements for better autocompletion and error handling. Integration with Eloquent or services is straightforward—options can trigger model operations or external API calls based on selection.
Ensure your command extends Illuminate\Console\Command and uses the correct namespace for the Menu class. The package depends on symfony/console, so confirm compatibility with your Laravel version (v3.7.0 now supports Laravel 13.x). Avoid large option lists (>50 items) as they may exceed terminal buffer limits. For complex workflows, consider breaking menus into stages using menu->clear() between steps. Changelog data was removed in this release—prior release notes must be accessed via commit history if needed.
How can I help you explore Laravel packages today?