In the end I found the problem - and this did help, but not as I expected.
It was actually in /etc/profile.d/vim.*. If the uid>100 vi is aliased to vim (so I get all the nice features) otherwise it's not and I dont. That's why I sometimes got the nice stuff and sometimes didn't. RH9 did a simple alias. Now I know, I can just change it. But ... why only alias for uid>100? Maybe they asumed that anyone using uid<0 knows what they are doing (so types vim not vi) :) Thanks all the same. On 7/11/06, Benji Fisher <[EMAIL PROTECTED]> wrote:
Do not have too much faith in RH. Several years ago, they included an alpha version of vim (6.0z, I think) in their release, and linked it to /bin/vi (or maybe /usr/bin/vi ). The last time I checked, the system vimrc file they included was seriously crufty. Have a look at the system vimrc files on the two systems. (See the end of the :version message for where these are, or the start of :scriptnames .) That should explain wuestion (2) from your original post, and maybe others. It will also give you a chance to decide for yourself whether I am right about the cruft. As a first step toward figuring out the highlighting problems, try :verbose set ft? syntax? in a file where it works and one where it does not. HTH --Benji Fisher On Mon, Jul 10, 2006 at 09:28:59AM +0100, dave--uk wrote: > I'm not really convinced that is the problem. Nothing really points to it. > > 1) Syntax highlighting does work for some files - if it was the build > it wouldn't work at all. > 2) Not remembering the file positions sounds like a configuration switch. > 3) The help files being opened binary, rather than uncompressed on the > fly, along with the associated message, strongly suggests this is a > config problem. > 4) I've used multiple binary builds, from different sources, all > giving exactly the same issues. > 5) It seems so unlikely that the official Centos-4 build of vi - > Centos is basically RHEL - is radically broken. Vi is pretty basic > stuff. I don't believe RH would ship and not fix a broken vi. > > If necessary I can build from source, but it's not my first choice! > > On 7/10/06, Yakov Lerner <[EMAIL PROTECTED]> wrote: > >On 7/10/06, dave--uk <[EMAIL PROTECTED]> wrote: > >> I used to use RH9 and was VERY happy with three features of vim (6.1.320) > >> 1) almost everything was syntax highlighted, including, for example, > >httpd.conf. > >> 2) when i edited a file, vim remembered the last position I was at > >> 3) the help worked > >> > >> Having moved to Centos-4 (RHEL) (vim 6.3.046) none of these work any > >more. > >> > >> I do get some syntax highlighting - for example of .cpp files - but > >> .conf files etc don't get highlighted anymore, and no file positions > >> are remembered. > >> > >> When I try to use help I get something like > >> > >> "quickref.txt.gz" [readonly][noeol] 83L, 20610C > >> E434: Can't find tag pattern > >> > >> then quickref.txt.gz is loaded binary. > >> > >> I've tried to find the cause myself by comparing the vimrc files etc, > >> and by searching google, but not found any answers. I even found and > >> installed v7 (from the rpm at > >> http://www.karan.org/blog/index.php/2006/05/10/p139) but this gives > >> exactly the same issues. > >> > >> I have the following vim packages installed: > >> vim-common.i386 2:7.0.000-2.el4.kb installed > >> vim-enhanced.i386 2:7.0.000-2.el4.kb installed > >> vim-minimal.i386 2:7.0.000-2.el4.kb installed > > > >You binary installation of vim seems to be > >bad/bogus/broken/befuddled. (may be even bedeviled). > > > >I recommend to install vim from sources. This is best. This > >is also easy. You need gcc installed. Then, (download > >tgz from http://www.vim.org/download.php#unix, > >./configure && make && make install), or follow > >instructions on http://www.vim.org/download.php#unix > > > >If you, for some reason, can't build & install from sources, then > >you can try binary rpms found on rpmfind.net. > >My guess is that many of rpms of over distros, listed > >on rpmfind.net, are installable on your distro, because > >vim generally has little external dependencies. But this is > >only an option if you can't build & install from sources, > >see above. > > > >Yakov > >