mirror of
https://github.com/sxyazi/yazi.git
synced 2026-07-25 08:41:05 +00:00
better error message
This commit is contained in:
parent
1338f9acbb
commit
c5b7186ea8
1 changed files with 1 additions and 1 deletions
|
|
@ -18,7 +18,7 @@ function M:preload()
|
||||||
local file_cmd_path = os.getenv("YAZI_FILE_CMD_PATH") or "file"
|
local file_cmd_path = os.getenv("YAZI_FILE_CMD_PATH") or "file"
|
||||||
local child, code = Command(file_cmd_path):args({ "-bL", "--mime-type" }):args(urls):stdout(Command.PIPED):spawn()
|
local child, code = Command(file_cmd_path):args({ "-bL", "--mime-type" }):args(urls):stdout(Command.PIPED):spawn()
|
||||||
if not child then
|
if not child then
|
||||||
ya.err("spawn `file` command returns " .. tostring(code))
|
ya.err(string.format("spawn `%s` command returns %s", file_cmd_path, tostring(code)))
|
||||||
return 0
|
return 0
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue