PHP code example of prestashop / php-dev-tools

1. Go to this page and download the library: Download prestashop/php-dev-tools library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

prestashop / php-dev-tools example snippets


$ _PS_ROOT_DIR_=<Path_to_PrestaShop> phpstan --configuration=tests/phpstan/phpstan.neon analyse <path1 [path2 [...]]>

$ _PS_ROOT_DIR_=<Path_to_PrestaShop> php ~/.composer/vendor/bin/phpstan.phar --configuration=tests/phpstan/phpstan.neon analyse <path1 [path2 [...]]>

$ vendor/bin/autoindex prestashop:add:index <path>

$ vendor/bin/header-stamp --license=assets/afl.txt --exclude=vendor,node_modules

composer 

composer global 
bash
$ vendor/bin/php-cs-fixer fix