fix: oldfiles cwd_only that include backslashes (windows) (#820)
This commit is contained in:
@@ -251,6 +251,7 @@ internal.oldfiles = function(opts)
|
|||||||
|
|
||||||
if opts.cwd_only then
|
if opts.cwd_only then
|
||||||
local cwd = vim.loop.cwd()
|
local cwd = vim.loop.cwd()
|
||||||
|
cwd = cwd:gsub([[\]],[[\\]])
|
||||||
results = vim.tbl_filter(function(file)
|
results = vim.tbl_filter(function(file)
|
||||||
return vim.fn.matchstrpos(file, cwd)[2] ~= -1
|
return vim.fn.matchstrpos(file, cwd)[2] ~= -1
|
||||||
end, results)
|
end, results)
|
||||||
|
|||||||
Reference in New Issue
Block a user