PHP code example of generoi / deployer-genero
1. Go to this page and download the library: Download generoi/deployer-genero 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/ */
generoi / deployer-genero example snippets
namespace Deployer;
etool.php';
php';
o/build.php';
p';
set('scaffold_machine_name', 'project-name');
set('scaffold_env_file', __DIR__ . '/.env.example');
set('theme_dir', 'web/app/themes/project-name');
set('shared_files', ['.env']);
set('shared_dirs', ['web/app/uploads', '{{cache_dir}}']);
set('writable_dirs', get('shared_dirs'));
set('bin/robo', './vendor/bin/robo');
set('bin/wp', './vendor/bin/wp');
set('bin/npm', function () {
return run('which npm');
});
/**
* Build configuration
*/
set('build_repository', __DIR__);
set('build_shared_dirs', ['{{theme_dir}}/node_modules']);
set('build_copy_dirs', ['{{theme_dir}}/vendor', 'vendor']);
set('build_path', __DIR__ . '/.build');
set('build_artifact_dir', '{{build_path}}/artifact');
set('build_artifact_exclude', [
'.git',
'node_modules',
'*.sql',
'/.*',
'/*.md',
'/config/*.yml',
'/config/patches',
'/composer.json',
'/composer.lock',
'/*.php',
'/*.xml',
'/*.yml',
'/Vagrantfile*',
]);
/**
* Deploy configuration
*/
set('rsync_src', '{{build_artifact_dir}}');
set('rsync_dest', '{{release_path}}');
set('rsync', [
'exclude' => [],
'success',
]);