daanbiesterbos / command-extra-bundle
Minimal symfony bundle that adds functionality to alias symfony commands.
Installs: 8
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 2
Forks: 0
Open Issues: 0
Type:symfony-bundle
Requires
- php: ^7.3
- symfony/config: ^4.4|^5
- symfony/console: ^4.4|^5
- symfony/dependency-injection: ^4.4|^5
Requires (Dev)
- phpunit/phpunit: ^9
- roave/security-advisories: dev-master
README
Installation
This bundle is available on Packagist. You can install it using Composer.
composer require daanbiesterbos/command-extra-bundle
Step 2: Enable the bundle
Add the bundle to config/bundles.php
return [ DaanBiesterbos\CommandExtraBundle\CommandExtraBundle::class => ['all' => true], ];
Step 3: Configure the bundle
Finally, configure the bundle:
# config/packages/command_extra.yaml command_extra: aliases: # Example 1: # Register alias to run a non symfony command. ps: name: 'ps' description: 'Shorthand example of a non symfony command.' execute: 'ps -aux' # This shorthand is for non-symfony commands only. # Example 2 # Register alias that runs two symfony commands when invoked. cache_purge: name: 'cache:purge' description: 'Prune cache pools and application cache.' execute: # Run multiple commands cache_pool: command: 'cache:pool:prune' symfony: true app_cache: command: 'cache:clear' symfony: true