mirror of
https://github.com/Eugeny/tabby.git
synced 2025-09-13 11:54:33 +00:00
preserve file modes for up- and downloads - fixes #4141
This commit is contained in:
@@ -71,7 +71,7 @@ export class DebugDecorator extends TerminalDecorator {
|
||||
|
||||
private async saveFile (content: string, name: string) {
|
||||
const data = Buffer.from(content)
|
||||
const transfer = await this.platform.startDownload(name, data.length)
|
||||
const transfer = await this.platform.startDownload(name, 0o644, data.length)
|
||||
if (transfer) {
|
||||
transfer.write(data)
|
||||
transfer.close()
|
||||
|
@@ -113,7 +113,7 @@ export class ZModemDecorator extends TerminalDecorator {
|
||||
this.showMessage(terminal, colors.bgYellow.black(' Offered ') + ' ' + details.name, true)
|
||||
this.logger.info('offered', xfer)
|
||||
|
||||
const transfer = await this.platform.startDownload(details.name, details.size)
|
||||
const transfer = await this.platform.startDownload(details.name, 0o644, details.size)
|
||||
if (!transfer) {
|
||||
this.showMessage(terminal, colors.bgRed.black(' Rejected ') + ' ' + details.name)
|
||||
xfer.skip()
|
||||
|
Reference in New Issue
Block a user