Symfony2 console command arguments vs options when to use what Symfony2 console command arguments vs options when to use what symfony symfony

Symfony2 console command arguments vs options when to use what


I would suggest use Arguments when You want to specify excecution-required values, like:

bin/console vendor:delete-entity 120

but not

bin/console vendor:delete-entity --id=120

You can use Options, when You want to alter the default execution scenario, like:

bin/console vendor:delete-entity 120 --dump-sql

or

bin/console vendor:bulk-create something --batch-size=100