PHP code example of coderstephen / robo-ftp
1. Go to this page and download the library: Download coderstephen/robo-ftp 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/ */
coderstephen / robo-ftp example snippets
class RoboFile extends \Robo\Tasks
{
use RoboFtp\FtpDeploy;
function deploy()
{
$ftp = $this->taskFtpDeploy('host', 'user', 'password')
->dir('/')
->from('.')
->exclude('build')
->exclude('cache')
->skipSizeEqual()
->skipUnmodified()
->run();
}
}
class RoboFile extends \Robo\Tasks
{
use RoboFtp\FtpDeploy;
function deploy()
{
$ftp = $this->taskFtpDeploy('host', 'user', 'password')
->dir('wwwroot')
->from('public')
->secure(false)
->run();
}
}