Results 1 to 6 of 6
Dear All,
I have installed Vmware on Windows Xp. On Vmware i have installed RHEL 5 update 3. Now when i use vi editor and try to split it into ...
- 03-10-2010 #1Just Joined!
- Join Date
- Oct 2008
- Posts
- 9
:sp command is not working in Vi editor
Dear All,
I have installed Vmware on Windows Xp. On Vmware i have installed RHEL 5 update 3. Now when i use vi editor and try to split it into multiple windows using :sp or :vsp command then it does not work. Whereas i have the same RHEL 5 update 3 in one of the application server, and there :sp works fine. I tried searching online with no success. please help finding out why its not working on vmware and how can we make it work.
Please help.
Regards,
Raghuvendra Kumar
- 03-10-2010 #2
i'm still kind of new, so someone correct me if i'm wrong, please.
i think :sp and :vsp don't work in vi. they do work in vim. maybe the vi on your application server is soft linked to vim and that's why they work there.
try soft linking your vi to vim in vmware, or just use vim.
i hope this helps.
- 03-13-2010 #3Just Joined!
- Join Date
- Oct 2008
- Posts
- 9
Yup.
I have figured out. vi is the minimal version. The advanced version is vim.
We can see by typing :-
type vi
type vim.
Just removed vi and created a soft-link for vim as vi.
Thanks for your Help.
Raghuvendra Kumar
- 03-13-2010 #4
On many systems, "vi" and "vim" both refer to the same vim program. However, when vim is started as "vi", a script is run to run vim in compatibility mode, which disables many of the more advanced vim features in order to provide as vi-like an experience as possible.
For that reason, on many systems, using an alias to set the "vi" command to "vim" may be better. That way, vim doesn't think it's running as vi, even on systems where you can't control the "vi" link.DISTRO=Arch
Registered Linux User #388732
- 03-13-2010 #5I do not respond to private messages asking for Linux help, Please keep it on the forums only.
All new users please read this.** Forum FAQS. ** Adopt an unanswered post.
- 03-14-2010 #6
The main purpose is that if you have old scripts that ran with vi, they will continue running exactly as expected, and won't be interfered with by new vim options and such.
However, doing a bit more research into it now, I see that it's actually pretty tough to get compatibility mode
. In particular, if you have set any custom vi settings (that is, you have a .vimrc file) and have not explicitly set compatibility mode, you won't get it.
Also, looking at my system in particular (which is Ubuntu 9.10):
So what I said before may just apply to older systems, and not more modern ones. I apologize.Code:alex@danu:~$ readlink -e /usr/bin/vi /usr/bin/vim.basic alex@danu:~$ readlink -e /usr/bin/vim /usr/bin/vim.basic
DISTRO=Arch
Registered Linux User #388732


Reply With Quote
