> I have also been wondering if we can make "gf" a bit more clever. > I sometimes end up copying a path because its end is not clear. > > The way you detect a ":" terminating the name looks a bit too simple. > How about file://c:/path ? > It would be good to add a comment to explain what it's doing at least. > > A crude but effective solution would be to first take the longest path, > see if it exists. If not, then try removing a part at the end and try > again. This would require a list of "optional file name characters". > We should not have more than two or three tries to avoid this taking a > long time (it's disk operations, and $PATH can contain many directories).
Updated patch: https://gist.github.com/mattn/9388140 (Not modified code, just only add comments) file://c:path should be worked correctly. The file: URL is passed to netrw, and netrw open the local paths. I'm thinking that it don't need to check the file is exists. Do you mean that the path which contains whitespace? Thanks. - Yasuhiro Matsumoto -- -- You received this message from the "vim_dev" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php --- You received this message because you are subscribed to the Google Groups "vim_dev" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
