Re: missing vim highlight

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Michael D. Berger wrote:
> Thanks for these clues, but it is not fixed yet.
> 
> :set hlsearch and :set nohlsearch work as expected on boxA, but
> have no effect on boxB.
> 
> boxB has only one user.  It is a web server, and login is only
> to examine the logs (where the highlight would be most useful)
> and for web upgrade.
> 
> Neither box has a .vimrc .  Only one person uses these boxes,
> so /etc/vimrc is adequate.
> 
> A surprising difference is that boxA has a .viminfo, but boxB
> does not.  I copied the .viminfo from boxA to boxB, but it
> had no effect.  I emphasize that the /etc/vimrc for the two
> boxes are identical, as I just reconfirmed.

So boxA has "normal" users and boxB just has root?

Run alias on both boxes: I bet you'll find root on boxB is running "vi",
whereas the alias on boxA means that when you type vi, you get vim.

This comes from /etc/profile.d/vim.sh which says
  [ `/usr/bin/id -u` -le 100 ] && return
  # for bash and zsh, only if no alias is already set
  alias vi >/dev/null 2>&1 || alias vi=vim
In other words, for accounts less than 100, the alias isn't set.

Handle that how you wish: I'd put something into root's ~/.bash_profile.

Hope this helps,

James.

-- 
E-mail address: james | Please do not put sandwiches in the disk drive.
@westexe.demon.co.uk  | 


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux