refactor(actions): remove linefeed on info messages. (#1450)

This commit is contained in:
John Fred Fadrigalan 2022-07-22 16:10:58 +08:00 committed by GitHub
parent 08ab346f03
commit d927e89aa9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 6 additions and 6 deletions

View File

@ -120,11 +120,11 @@ local function add_to_clipboard(node, clip)
for idx, _node in ipairs(clip) do
if _node.absolute_path == node.absolute_path then
table.remove(clip, idx)
return utils.notify.info(node.absolute_path .. " removed to clipboard.\n")
return utils.notify.info(node.absolute_path .. " removed to clipboard.")
end
end
table.insert(clip, node)
utils.notify.info(node.absolute_path .. " added to clipboard.\n")
utils.notify.info(node.absolute_path .. " added to clipboard.")
end
function M.copy(node)
@ -218,11 +218,11 @@ local function copy_to_clipboard(content)
if M.use_system_clipboard == true then
vim.fn.setreg("+", content)
vim.fn.setreg('"', content)
return utils.notify.info(string.format("Copied %s to system clipboard! \n", content))
return utils.notify.info(string.format("Copied %s to system clipboard!", content))
else
vim.fn.setreg('"', content)
vim.fn.setreg("1", content)
return utils.notify.info(string.format("Copied %s to neovim clipboard \n", content))
return utils.notify.info(string.format("Copied %s to neovim clipboard!", content))
end
end

View File

@ -100,7 +100,7 @@ function M.fn(node)
end
end
if not is_error then
utils.notify.info(new_file_path .. " was properly created\n")
utils.notify.info(new_file_path .. " was properly created")
end
events._dispatch_folder_created(new_file_path)
if M.enable_reload then

View File

@ -20,7 +20,7 @@ function M.rename(node, to)
if not success then
return utils.notify.warn(err_fmt(node.absolute_path, to, err))
end
utils.notify.info(node.absolute_path .. "" .. to .. "\n")
utils.notify.info(node.absolute_path .. "" .. to)
utils.rename_loaded_buffers(node.absolute_path, to)
events._dispatch_node_renamed(node.absolute_path, to)
end