PHP code example of justbetter / magento2-deployer-plus

1. Go to this page and download the library: Download justbetter/magento2-deployer-plus 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/ */

    

justbetter / magento2-deployer-plus example snippets


	// deploy.php
	 task('files:static_assets', function () {
		run('{{bin/php}} {{magento_bin}} setup:static-content:deploy en_US {{static_deploy_options}}');
		run('{{bin/php}} {{magento_bin}} setup:static-content:deploy de_CH {{static_deploy_options}}');
		run('{{bin/php}} {{magento_bin}} setup:static-content:deploy fr_FR {{static_deploy_options}}');
	 });
	

cp <vendor_dir>/justbetter/magento2-deployer-plus/deploy.php.sample_2_1 deploy.php

cp <vendor_dir>/justbetter/magento2-deployer-plus/deploy.php.sample_2_2 deploy.php

cp <vendor_dir>/justbetter/magento2-deployer-plus/deploy.php.sample_2_2_5 deploy.php

		// deploy.php
		task('files:static_assets')->onRoles('Skip');