pkt / lh-vim

Luc Hermitte's lh-vim to save it from google code closing
0 stars 0 forks source link

[Defect] Find_in_parents does not work under cygwin #50

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Calling

lh#path#find_in_parents('/cygdrive/d/_P/tesfile', ['_vimrc_local.vim'], 
'file,dir', '^/\=$\|^[A-Za-z]:\+$\|^//$\|^\\\\$\|^[/\\]home[/\\]uidw8099$')

prints the warning:

The current file '/cygdrive/d/_P/testfile' seems to be in a non-existent 
directory: ''

It seems that the last_valid_path is wrong. This could stem from the fact that 
when opening the file the path is "~/d/_P/testfile" and "d" is a symlink to 
"/cygdrive/d".

Original issue reported on code.google.com by guibuf...@gmail.com on 11 Sep 2014 at 12:26

GoogleCodeExporter commented 9 years ago
The problems seem to come from the fact that vim reports 
isreadable('//_local_vimrc.vim') == 1 although the file does not exist.

I modified the file:
 477:  if path != '/' && up_path == '.' " Likely a non existent path

 497:  if path == '/'
 498:    let path = ''
 499:  endif

And it seems to work.

Original comment by guibuf...@gmail.com on 11 Sep 2014 at 1:46

GoogleCodeExporter commented 9 years ago
Thank you for the bug report.

I took another path in order to fix the bug -- I've been wanting to simplify 
the function for a log time, and I've still some work to do :(

It should be fixed since r870. I recommend you to update local_vimrc as well.

Let me know if the bug is fixed on your side as well.

Original comment by luc.herm...@gmail.com on 12 Sep 2014 at 9:21

GoogleCodeExporter commented 9 years ago
Unfortunately i us lh-vim from github. Is it up to date there too?

Original comment by guibuf...@gmail.com on 12 Sep 2014 at 9:32

GoogleCodeExporter commented 9 years ago
That may explain why your line numbers weren't matching mine...

No it is not. The best way to always have an up-to-date version is to use this 
subversion repository. Which github version are you using ? The one from 
alerque or the one which is automatically updated from vim.org (vim-scripts) ?

Note, if you are not using Vundle but neobundle, it should (*) find lh-vim-lib 
automatically -- AFAIK, NeoBundle should now rely on vim-pi which is able to 
tell where to find lh-vim-lib. 

(*) I need to test it.

Original comment by luc.herm...@gmail.com on 12 Sep 2014 at 9:53

GoogleCodeExporter commented 9 years ago
If you are using NeoBundle, I have updated to installation doc of local_vimrc 
in consequence.

Original comment by luc.herm...@gmail.com on 12 Sep 2014 at 10:42

GoogleCodeExporter commented 9 years ago
I'm using the one from vim-scripts. Sorry not using NeoBundle but Vundle.

Original comment by guibuf...@gmail.com on 12 Sep 2014 at 12:02

GoogleCodeExporter commented 9 years ago
I've published the vimball on vim.org, vim-scripts will get updated in a few 
hours/days.

But please, Vundle is really not fit for plugins like the ones I'm maintaining. 
There are too many dependencies and Vundle will never support them (nor svn). :(

Original comment by luc.herm...@gmail.com on 12 Sep 2014 at 12:08