PHP code example of optimistex / git-auto-deploy-ex

1. Go to this page and download the library: Download optimistex/git-auto-deploy-ex 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/ */

    

optimistex / git-auto-deploy-ex example snippets


    $ composer 

    
    cret code in the first parameter for protection
    (new \optimistex\deploy\DeployApplication('ytJHvMHFdTYUryDhmJkjFjFiYk'))->run();
    

    
    cret code in the first parameter for protection
    (new \optimistex\deploy\DeployApplication('ytJHvMHFdTYUryDhmJkjFjFiYk'))->run();
    



use optimistex\deploy\DeployApplication;

 // executing custom commands
    'git branch',                               // equal: $ git branch
    'git pull',                                 // equal: $ git pull
    'php' => 'composer.phar install',           // equal: $ php composer.phar install
    ['php' => 'yii migrate --interactive=0'],   // equal: $ php yii migrate --interactive=0
]);