feat: most moves and copies will copy the undofile (#583)
This commit is contained in:
parent
5313690956
commit
32dd3e378d
4 changed files with 51 additions and 6 deletions
|
|
@ -151,7 +151,7 @@ end
|
|||
---@field info_file string
|
||||
---@field original_path string
|
||||
---@field deletion_date number
|
||||
---@field stat uv_fs_t
|
||||
---@field stat uv.aliases.fs_stat_table
|
||||
|
||||
---@param info_file string
|
||||
---@param cb fun(err?: string, info?: oil.TrashInfo)
|
||||
|
|
@ -596,8 +596,7 @@ M.perform_action = function(action, cb)
|
|||
if err then
|
||||
cb(err)
|
||||
else
|
||||
---@diagnostic disable-next-line: undefined-field
|
||||
local stat_type = trash_info.stat.type
|
||||
local stat_type = trash_info.stat.type or "unknown"
|
||||
fs.recursive_copy(stat_type, path, trash_info.trash_file, vim.schedule_wrap(cb))
|
||||
end
|
||||
end)
|
||||
|
|
@ -625,8 +624,7 @@ M.delete_to_trash = function(path, cb)
|
|||
if err then
|
||||
cb(err)
|
||||
else
|
||||
---@diagnostic disable-next-line: undefined-field
|
||||
local stat_type = trash_info.stat.type
|
||||
local stat_type = trash_info.stat.type or "unknown"
|
||||
fs.recursive_move(stat_type, path, trash_info.trash_file, vim.schedule_wrap(cb))
|
||||
end
|
||||
end)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue