Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some questions about the configuration #3

Open
g-i-o-r-g-i-o opened this issue Feb 1, 2018 · 8 comments
Open

Some questions about the configuration #3

g-i-o-r-g-i-o opened this issue Feb 1, 2018 · 8 comments
Labels

Comments

@g-i-o-r-g-i-o
Copy link

g-i-o-r-g-i-o commented Feb 1, 2018

Hello, I'm having some problems with vim 8: I've installed it with this vimrc line, but none of the keybindings work:
Plug 'https://github.com/vim-scripts/perl-support.vim'
Instead of using my defined leader key, it uses \

Furthermore vim (or this plugin) doesn't use the perl version that is normally loaded with terminal, and that I've installed with perlbrew, but an ancient version that come with ubuntu.

@WolfgangMehner
Copy link
Owner

Please try my own repo: https://github.com/WolfgangMehner/perl-support
In the last years, vim-scripts does not update its repos anymore, certainly not this one.

Do the keybindings work with my repo?

@g-i-o-r-g-i-o
Copy link
Author

Thanks, now it works, not with my defined leader key, but only with \

Another problem is that vim (or this plugin) doesn't use the perl version that is normally loaded with terminal, and that I've installed with perlbrew, but an ancient version that come with ubuntu.

@WolfgangMehner
Copy link
Owner

The mapleader can be set for Perl-Support specifically, using the configuration variable g:Perl_MapLeader, e.g.:

let g:Perl_MapLeader = '#'

As a fallback, maplocalleader is used, not mapleader.

@WolfgangMehner
Copy link
Owner

The executable can also be configured. Does this work?

let s:Perl_Executable = 'perl'

You may also compare this discussion: WolfgangMehner/vim-plugins#11

On the other hand. the perlbrew issue comes up from time to time. Is there a way to reliably detect the perlbrew installation under Linux and obtain its values for the executable (and modules, ...)?

@WolfgangMehner WolfgangMehner changed the title does this work with vim 8? Some questions about the configuration Feb 1, 2018
@g-i-o-r-g-i-o
Copy link
Author

Thanks for helping abut the leader, but still I can't figure out the perl path...

@lbe
Copy link

lbe commented May 5, 2019

The executable can also be configured. Does this work?

let s:Perl_Executable = 'perl'

You may also compare this discussion: WolfgangMehner/vim-plugins#11

On the other hand. the perlbrew issue comes up from time to time. Is there a way to reliably detect the perlbrew installation under Linux and obtain its values for the executable (and modules, ...)?

perlbrew updates the user's PATH environment variable. I'm not very knowledgable in vimscript and don't know how it would be implemented. But the implementation should be equivalent to which command or the bash shebang handling of "#!/usr/bin/env perl". HTH lbe

@WolfgangMehner
Copy link
Owner

Let's debug this, so we start with the obvious.

  • When you run :echo $PATH on the Vim command-line, does it include the path currently configured and required by perlbrew?
  • Could you post the output of :call Perl_Settings(2)?
  • Did you actually add the line let s:Perl_Executable = 'perl' to your configuration, e.g. .vimrc?

The default should be let s:Perl_Executable = 'perl' obviously, I will fix this.

@g-i-o-r-g-i-o
Copy link
Author

Hello, it seems to work under linux. I've just updated the perl in use using perlbrew.
Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants