2013-12-12 15:15:44 +01:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace PHPCI\Helper;
|
|
|
|
|
2014-05-09 14:09:27 +02:00
|
|
|
interface CommandExecutor
|
2013-12-12 15:15:44 +01:00
|
|
|
{
|
|
|
|
/**
|
2014-05-09 14:09:27 +02:00
|
|
|
* Executes shell commands. Accepts multiple arguments the first
|
|
|
|
* is the template and everything else is inserted in. c.f. sprintf
|
2013-12-12 15:15:44 +01:00
|
|
|
* @return bool Indicates success
|
|
|
|
*/
|
2014-05-09 14:09:27 +02:00
|
|
|
public function executeCommand();
|
2013-12-12 15:15:44 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns the output from the last command run.
|
|
|
|
*/
|
2014-05-09 14:09:27 +02:00
|
|
|
public function getLastOutput();
|
2013-12-12 17:17:11 +01:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Find a binary required by a plugin.
|
2014-05-09 10:21:53 +02:00
|
|
|
* @param string $binary
|
2013-12-12 17:17:11 +01:00
|
|
|
* @return null|string
|
|
|
|
*/
|
2014-05-09 14:09:27 +02:00
|
|
|
public function findBinary($binary);
|
2013-12-12 15:15:44 +01:00
|
|
|
}
|