deployphp/deployer

View on GitHub
recipe/deploy/env.php

Summary

Maintainability
A
0 mins
Test Coverage
<?php

namespace Deployer;

set('dotenv_example', '.env.example');

desc('Configure .env file');
task('deploy:env', function () {
    cd('{{release_or_current_path}}');
    if (test('[ ! -f .env ] && [ -f {{dotenv_example}} ]')) {
        run('cp {{dotenv_example}} .env');
        set('new_deployment', true);
    }
});