mirror of
https://github.com/Eugeny/tabby.git
synced 2024-11-22 20:55:03 +03:00
ssh: fixed newlines in banners/MOTD - fixes #5905
This commit is contained in:
parent
b31b500727
commit
f073a691fc
@ -124,6 +124,7 @@ export class SSHTabComponent extends BaseTerminalTabComponent {
|
|||||||
}
|
}
|
||||||
|
|
||||||
this.attachSessionHandler(session.serviceMessage$, msg => {
|
this.attachSessionHandler(session.serviceMessage$, msg => {
|
||||||
|
msg = msg.replace(/\n/g, '\r\n ')
|
||||||
this.write(`\r${colors.black.bgWhite(' SSH ')} ${msg}\r\n`)
|
this.write(`\r${colors.black.bgWhite(' SSH ')} ${msg}\r\n`)
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -202,6 +203,7 @@ export class SSHTabComponent extends BaseTerminalTabComponent {
|
|||||||
const session = new SSHShellSession(this.injector, this.sshSession)
|
const session = new SSHShellSession(this.injector, this.sshSession)
|
||||||
this.setSession(session)
|
this.setSession(session)
|
||||||
this.attachSessionHandler(session.serviceMessage$, msg => {
|
this.attachSessionHandler(session.serviceMessage$, msg => {
|
||||||
|
msg = msg.replace(/\n/g, '\r\n ')
|
||||||
this.write(`\r${colors.black.bgWhite(' SSH ')} ${msg}\r\n`)
|
this.write(`\r${colors.black.bgWhite(' SSH ')} ${msg}\r\n`)
|
||||||
session.resize(this.size.columns, this.size.rows)
|
session.resize(this.size.columns, this.size.rows)
|
||||||
})
|
})
|
||||||
|
Loading…
Reference in New Issue
Block a user