Mercurial > hg > cmmr2012-drupal-site
comparison vendor/consolidation/site-process/src/Transport/TransportInterface.php @ 5:12f9dff5fda9 tip
Update to Drupal core 8.7.1
author | Chris Cannam |
---|---|
date | Thu, 09 May 2019 15:34:47 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
4:a9cd425dd02b | 5:12f9dff5fda9 |
---|---|
1 <?php | |
2 | |
3 namespace Consolidation\SiteProcess\Transport; | |
4 | |
5 use Consolidation\SiteProcess\SiteProcess; | |
6 | |
7 /** | |
8 * SshTransport knows how to wrap a command such that it runs on a remote | |
9 * system via the ssh cli. | |
10 * | |
11 * There is always a transport for every factory, and visa-versa. | |
12 * | |
13 * @see Consolidation\SiteProcess\Factory\TransportFactoryInterface | |
14 */ | |
15 interface TransportInterface | |
16 { | |
17 /** | |
18 * Configure ourselves based on the settings of the process object | |
19 * (e.g. isTty()). | |
20 * | |
21 * @param \Consolidation\SiteProcess\SiteProcess $process | |
22 */ | |
23 public function configure(SiteProcess $process); | |
24 | |
25 /** | |
26 * wrapWithTransport examines the provided site alias; if it is a local | |
27 * alias, then the provided arguments are returned unmodified. If the | |
28 * alias points at a remote system, though, then the arguments are | |
29 * escaped and wrapped in an appropriate ssh command. | |
30 * | |
31 * @param array $args arguments provided by caller. | |
32 * @return array command and arguments to execute. | |
33 */ | |
34 public function wrap($args); | |
35 | |
36 /** | |
37 * addChdir adds an appropriate 'chdir' / 'cd' command for the transport. | |
38 */ | |
39 public function addChdir($cd, $args); | |
40 } |