PHP code example of jasny / robo-extensions

1. Go to this page and download the library: Download jasny/robo-extensions 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/ */

    

jasny / robo-extensions example snippets


class RoboFile extends Robo\Tasks
{
    use Jasny\Robo\loadTasks;
    
    ...
}

  $this->taskLess(['www/less/main.less' => 'www/css/style.css'])
    ->compiler('less', [
       'base' => 'www',
       'strictMath' => true
    ])
    ->run();

  $this->taskBumpVersion('composer.json')
    ->inc('minor')
    ->run();

  $this->taskBumpVersion('composer.json')
    ->to('1.2.6')
    ->run();

  // `to` also works for 'major', 'minor' and 'patch'
  $this->taskBumpVersion('composer.json')
    ->to('minor')
    ->run();

  // Check the git tags
  $this->taskBumpVersion('composer.json')
    ->inc('patch')
    ->useGit()
    ->run();