Updates utils
This commit is contained in:
parent
f9aa694520
commit
2162ce7744
1 changed files with 4 additions and 0 deletions
|
|
@ -35,6 +35,10 @@ function search_ancestors(startpath, func)
|
|||
end
|
||||
end
|
||||
|
||||
local function escape_wildcards(path)
|
||||
return path:gsub('([%[%]%?%*])', '\\%1')
|
||||
end
|
||||
|
||||
function strip_archive_subpath(path)
|
||||
-- Matches regex from zip.vim / tar.vim
|
||||
path = vim.fn.substitute(path, 'zipfile://\\(.\\{-}\\)::[^\\\\].*$', '\\1', '')
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue