mirror of
https://github.com/Ascyii/telekasten.nvim.git
synced 2026-01-01 06:14:23 -05:00
fix: paste image error with os.execute (closes #241)
This commit is contained in:
@@ -403,7 +403,7 @@ local function imgFromClipboard()
|
|||||||
local relpath = make_relative_path(vim.fn.expand("%:p"), png, "/")
|
local relpath = make_relative_path(vim.fn.expand("%:p"), png, "/")
|
||||||
|
|
||||||
local result = os.execute(get_paste_command(pngdir, pngname))
|
local result = os.execute(get_paste_command(pngdir, pngname))
|
||||||
if result > 0 then
|
if not result then
|
||||||
vim.api.nvim_err_writeln(
|
vim.api.nvim_err_writeln(
|
||||||
string.format(
|
string.format(
|
||||||
"Unable to write image %s (exit code: %d). Is there an image on the clipboard? ",
|
"Unable to write image %s (exit code: %d). Is there an image on the clipboard? ",
|
||||||
|
|||||||
Reference in New Issue
Block a user