ktonga / vim-follow-my-lead

Vim plugin for showing all your <Leader> mappings in a readable table including the descriptions.
105 stars 9 forks source link

FML not working under GVim for Windows #11

Open pmcRTR opened 9 years ago

pmcRTR commented 9 years ago

I use GVim on both Windows and Linux. FML works fine on Linux but not on Windows. Currently I'm using the pre-compiled 64-Bit Windows GVim available from kaoriya.net (version 7.843).

running fml on GVim for Windows gives the following errors:

Error detected while processing function FMLShow..FMLGetLeaderMappingsBySource: line 22: E121: Undefined variable: s:vimrc_glob E116: Invalid arguments for function remove(with_desc, s:vimrc_glob) E15: Invalid expression: remove(with_desc, s:vimrc_glob) line 23: E121: Undefined variable: s:vimrc_glob E15: Invalid expression: [{ 'source': s:vimrc_glob, 'mappings': vimrc_val }] line 24: E121: Undefined variable: vimrc_first line 25: E121: Undefined variable: vimrc_first E15: Invalid expression: vimrc_first Error detected while processing function FMLShow: line 1: E712: Argument of map() must be a list or Dictionary E714: List required

ktonga commented 9 years ago

Taking a look at the error it seems it is having problems to detect vimrc from the rest of the sources. I don't have any Windows box to test it on.

Could you please attach the output of :verbose map and :echo $MYVIMRC ?

Thank you for reporting.

pmcRTR commented 9 years ago

echo $MYVIMRC == pathToMyHomeDir_vimrc (note on Windows vimrc filename starts with a _ and not a . as filenames beginning with a . is not supported / allowed)

verbose map output is too long to post in full here - is there a way for me to attach a .txt file or if you like I can send to you via email?

ktonga commented 9 years ago

I think it can be related to the _ or the \ when trying to do the matching. I don't need the whole output, just look for a line with the form: Last set from <relative_path_to_vimrc> And please add the output of :echo glob('<relative_path_to_vimrc>')

Thanks again.

pmcRTR commented 9 years ago

Running echo glob('~') returns C:\Users\pmc

In the output of verbose map, all the lines with that form look like:

Last set from ~_vimrc

ktonga commented 9 years ago

You didn't put the real output for :echo $MYVIMRC. is it C:\Users\pmc\_vimrc ? And please let me know the output of :echo glob('~\_vimrc') they should be the same for it to work.

pmcRTR commented 9 years ago

:echo $MYVIMRC returns C:\Users\pmc_vimrc

:echo glob('~_vimrc') also returns C:\Users\pmc_vimrc

ktonga commented 9 years ago

Hi @pmcRTR I wasn't able to reproduce it. The comparison is working as expected in my linux box for the windows paths you provided. Maybe we can work on it together if you help me debugging on your side. Ping me privately to my email when you can.

pmcRTR commented 9 years ago

Sure, I can help with debugging - no problem :)

Probably a n00b question but where can I find your email address?

ktonga commented 9 years ago

It should be in any of my commits. You already have the repo cloned. Use git log for listing the commits, my mail should be there.

On Thu, Oct 1, 2015, 06:42 pmcRTR notifications@github.com wrote:

Sure, I can help with debugging - no problem :)

Probably a n00b question but where can I find your email address?

— Reply to this email directly or view it on GitHub https://github.com/ktonga/vim-follow-my-lead/issues/11#issuecomment-144537220 .