Skip to content

Commit b034793

Browse files
author
wushuiyong
committed
add tty to support sudo
1 parent 2aae086 commit b034793

3 files changed

Lines changed: 6 additions & 6 deletions

File tree

components/Command.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,10 +87,10 @@ final protected function runLocalCommand($command) {
8787
*/
8888
final protected function runRemoteCommand($command) {
8989
$this->log = '';
90-
$needs_tty = '';
90+
$needTTY = ' -t ';
9191

9292
foreach (GlobalHelper::str2arr($this->getConfig()->hosts) as $remoteHost) {
93-
$localCommand = 'ssh ' . $needs_tty . ' -p ' . $this->getHostPort($remoteHost)
93+
$localCommand = 'ssh ' . $needTTY . ' -p ' . $this->getHostPort($remoteHost)
9494
. ' -q -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no '
9595
. $this->getConfig()->release_user . '@'
9696
. $this->getHostName($remoteHost);

messages/en/w.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
'default trunk' => 'default no trunk',
3030
'conf_status_0' => 'Invalid',
3131
'conf_status_1' => 'Valid',
32-
'conf_audit_0' => 'Yes',
33-
'conf_audit_1' => 'No',
32+
'conf_audit_0' => 'No',
33+
'conf_audit_1' => 'Yes',
3434
'conf_status_0_color' => 'text-danger',
3535
'conf_status_1_color' => 'text-success',
3636

messages/zh/w.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@
2929
'default trunk' => '默认无trunk',
3030
'conf_status_0' => '无效',
3131
'conf_status_1' => '有效',
32-
'conf_audit_0' => '',
33-
'conf_audit_1' => '',
32+
'conf_audit_0' => '',
33+
'conf_audit_1' => '',
3434
'conf_status_0_color' => 'text-danger',
3535
'conf_status_1_color' => 'text-success',
3636

0 commit comments

Comments
 (0)