Loading ...
Sorry, an error occurred while loading the content.

41414Re: weird 'rtp' problem

Expand Messages
  • Bram Moolenaar
    Jul 2, 2003
    • 0 Attachment
      Hari Krishna Dara wrote:

      > > > As the HOME directory is the current directory, it should pick the
      > > > .vimrc that you just created. But since the HOME directory is
      > > > modified to your actualy home directory and the rpt contains this
      > > > directory, you can observe that all your plugins will be loaded as
      > > > usual. But if you try to get the help on any installed plugins,
      > > > Vim says that the tag is not found. You can verify that the
      > > > directory exists in the 'rtp'. If you add the directory again,
      > > > then it seems to pick it up. Also, if you use the full path in the
      > > > directory instead of "~", then also it seems to pick it up fine.
      > > > This looks like a bug to me.
      > >
      > > This is a bit complicated to reproduce. What is the value of
      > > 'runtimepath' after all this? Use this command:
      > >
      > > :echo &runtimepath
      > >
      > > Vim will search for "doc/tags" files in all directories in
      > > 'runtimepath'. I can only imagine the value of 'runtimepath' is wrong.
      > >
      > > Note that using a value for $HOME that is not an absolute path is very
      > > unusual, this might cause trouble anyway.
      > >
      > For the matter of fact, the actual case is more complicated than this,
      > and I don't use a relative path as the HOME path either. You can very
      > well use /tmp/vim as the HOME path to start with.
      > I tried the scenario again with "c:\tmp\vim" as the HOME diretory to start
      > with and "c:\hari" as the new HOME directory (set from inside vimrc).
      > The 'rtp' value after vim starts up:
      > runtimepath=~/package/vim,c:\tmp\vim/vimfiles,c:/win32-gnu/vim,c:\tmp\vim/vimfiles/after

      Did you really use:

      :echo &runtimepath

      That matters, because ":set runtimepath" will shorten $HOME to "~" while
      ":echo" doesn't do that.

      If you did use ":echo" then the problem is that you have an unexpanded
      "~" in the option value, that won't work. If that is not the problem,
      then I can't see anything wrong. "~/package/vim" is where your
      "doc/tags" file is located, thus that _should_ work. But that "~/"
      really must be the full path.

      I still don't see what actually goes wrong, but it must have something
      to do with changing the value of $HOME while starting up. That means
      the value to which "~/" expands is not predictable.

      Life would be so much easier if we could just look at the source code.

      /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
      /// Creator of Vim - Vi IMproved -- http://www.Vim.org \\\
      \\\ Project leader for A-A-P -- http://www.A-A-P.org ///
      \\\ Help AIDS victims, buy here: http://ICCF-Holland.org/click1.html ///
    • Show all 6 messages in this topic