Type
magento2-module
Magento 2 sample console command for getting product info
magento2-module
OSL-3.0, AFL-3.0
None
None
None
None
None
None
Magento2 sample console command for getting product info
Run the following command in Magento 2 root folder:
composer require ruchlewicz/magento2-console-command
php bin/magento setup:upgrade
Download the repository and put the code into
app/code/Ruchlewicz/ConsoleCommand
Open console and run following command
php bin/magento ruchlewicz:product-info <product-id> -a <attribute-code>