Inspired by the frosh tinker
that inspired by laravel tinker
command from laravel this plugin adds a similar command to Shopware 6.
It's basically a fork version of frosh tinker
for Shopware 6 with additional features.
Read more:
frosh/tinker
repositorybobthecow/psysh
repository
bin/console sw:psysh
- Enter
ls
to get list of scoped variables. - Enter
list
to get list of avaialbe commands.
-
Shopware's Core Services aliases (e.g new EqualsFilter via CLI instead of fully qualified class name
Shopware\Core\Framework\DataAbstractionLayer\Search\Filter\EqualsFilter
. (There is some rare cases that two classes use the same class alias so you need to give the fullname to make it work) -
Default scoped variables: $container (Service Container object), $connection (Doctrine Connection object), $context (Default context object), $criteria (default criteria object)...and more
- Shopware 6.3 or above (older versions might work, but were not tested)
- PHP 7.1 or above
composer require vin-sw/psysh
bin/console plugin:refresh
bin/console plugin:install --activate ShopwarePsysh
bin/console sw:psysh
Feel free to fork and send pull requests!
This project uses the MIT License.