Skip to content
This repository was archived by the owner on Sep 16, 2021. It is now read-only.

Commit a0a5796

Browse files
aboksantonmedv
authored andcommitted
Fix outdated docs about run() returning Result (#123)
Since deployphp/deployer@53b0261, `run()` and `runLocally()` do not return an instance of `Result` anymore, just a `string`.
1 parent 60a78af commit a0a5796

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

api.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ workingPath() == '/var/www/app/releases/1';
9999

100100
### run
101101

102-
* `run(string $command, $options = []): Result`
102+
* `run(string $command, $options = []): string`
103103

104104
Run a command on remote host. Available options:
105105

@@ -114,7 +114,7 @@ For example, if your private key contains a passphrase, enable tty and you'll se
114114
run('git clone ...', ['timeout' => null, 'tty' => true]);
115115
~~~
116116

117-
`run` function returns an instance of the `Result` class, which can be easily cast to string:
117+
`run` function returns the output of the command as a string:
118118

119119
~~~php
120120
$path = run('readlink {{deploy_path}}/current');
@@ -123,7 +123,7 @@ run("echo $path");
123123

124124
### runLocally
125125

126-
* `runLocally($command, $options = []): Result`
126+
* `runLocally($command, $options = []): string`
127127

128128
Run a command on localhost. Available options:
129129

0 commit comments

Comments
 (0)