mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
Change stdout to the correct option of tar
This commit is contained in:
parent
89f83efb90
commit
3f17bbdc60
1 changed files with 1 additions and 1 deletions
|
|
@ -54,7 +54,7 @@ function M:seek(units)
|
||||||
end
|
end
|
||||||
|
|
||||||
function M:spawn_tar(args)
|
function M:spawn_tar(args)
|
||||||
local stdout = args[1] == "l" and Command.PIPED or Command.NULL
|
local stdout = args[1] and args[1]:sub(0, 2) == "-t" and Command.PIPED or Command.NULL
|
||||||
local child, code = Command("tar"):args(args):stdout(stdout):stderr(Command.PIPED):spawn()
|
local child, code = Command("tar"):args(args):stdout(stdout):stderr(Command.PIPED):spawn()
|
||||||
if not child then
|
if not child then
|
||||||
return nil, "Failed to spawn, error code: " .. tostring(code)
|
return nil, "Failed to spawn, error code: " .. tostring(code)
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue