2017 © Pedro Peláez
 

library process

Process plugin for Task

image

task/process

Process plugin for Task

  • Sunday, May 4, 2014
  • by mbfisher
  • Repository
  • 2 Watchers
  • 2 Stars
  • 2,257 Installations
  • PHP
  • 2 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 7 Versions
  • 6 % Grown

The README.md

task/process

Build Status Coverage Status, (*1)

Installation

Install via Composer:, (*2)

...
    "require-dev": {
        "task/process": "~0.2"
    }
...

Usage

Inject into the project container:, (*3)

use Task\Plugin\ProcessPlugin;

$project->inject(function ($container) {
    $container['ps'] = new ProcessPlugin;
});

$project->addTask('whoami', ['ps', function ($ps) {
    $ps->run('whoami')->pipe($this->getOutput());
}]);

API

run($command, array $args = [], $cwd = null, array $env = [], OutputInterface $output = null)

$command - The command run:, (*4)

run('whoami');

array $args = [] - An array of command line arguments:, (*5)

run('ls', ['-la']);

$cwd = null - The directory to execute the command in:, (*6)

run('du', ['-hs'], '/path/to/my/project');

$env - An array of environment variables:, (*7)

run('myscript', [], null, ['DEBUG' => 1]);
build($command, array $args = [])

Accepts the same $command and $args arguments as run, but returns an instance of Task\Plugin\Process\ProcessBuilder, which thinly wraps Symfony's ProcessBuilder, providing an OO interface to confguration a command., (*8)

The Versions

04/05 2014
03/05 2014

v0.3.0

0.3.0.0

Process plugin for Task

  Sources   Download

MIT

The Requires

 

The Development Requires

by Mike Fisher

01/05 2014

v0.2.0

0.2.0.0

Process plugin for Task

  Sources   Download

MIT

The Requires

 

The Development Requires

by Mike Fisher

23/04 2014

v0.1.2

0.1.2.0

Process plugin for Task

  Sources   Download

MIT

The Requires

 

The Development Requires

by Mike Fisher

23/04 2014

v0.1.1

0.1.1.0

Process plugin for Task

  Sources   Download

MIT

The Requires

 

The Development Requires

by Mike Fisher

23/04 2014

v0.1.0

0.1.0.0

Process plugin for Task

  Sources   Download

MIT

The Requires

 

The Development Requires

by Mike Fisher