From: Peter Jankuliak Date: Sat, 13 May 2023 15:47:09 +0000 (+0100) Subject: Update comment X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=fb1827155cebf1c03eecc5bb4953ceb0241b3055;p=vim-lsp.git Update comment --- diff --git a/autoload/lsp/util.vim b/autoload/lsp/util.vim index f9add18..b9cb138 100644 --- a/autoload/lsp/util.vim +++ b/autoload/lsp/util.vim @@ -112,9 +112,9 @@ export def LspFileToUri(fname: string): string var uri: string = fname->fnamemodify(':p') if has("win32unix") - # We're in Cygwin, we need to convert POSIX style paths to Windows style. - # `cygpath -m` converts paths of the form "/cygdrive/c/foo/bar" to "C:/foo/bar", and - # paths of the form "/home/pete/foo" to "C:/cygwin64/home/pete/foo". + # We're in Cygwin, convert POSIX style paths to Windows style. + # The substitution is to remove the '^@' escape character from the end of + # line. uri = system($'cygpath -m {uri}')->substitute('^\(\p*\).*$', '\=submatch(1)', "") endif