View Full Version : vi in slackware...


BrokenArrow
hi everyone...


i just installed slackware 8.1. when i tried to edit files with vi, it kinda felt weird. i can't use the backspace key there. to be more specific, i can't backspace any thing that is already written in a file. yet, if i just added somehting. i can do whatever i want with it!!


i know -from my experiance with red hat- that vi is just a simlink to vim. i check and it's linked to some 'beta3' named 'elvis'. it's man page says it's "a clone of the ex/vi text editor".


vim is still there. yet, when i used it, backspace works...and the arrow keys print letters when i use them in the insert mode!!!

now status is...

in vi\elvis, backspace doesn't work...

in vim, backspace workes fine but arrow keys dont work..

i searched for the vi proplem and found a lot of people asking about it. but didnt dinf any good answers.

after i played a little with vim, i found that it works fine if i ran these commands in vim command mode..

:set nocp
:set bs=2

so i created a /usr/share/vim/vimrc and put this in it. and it works fine know, but i still want to fix vi :)

did anyone fix this...

habdin
Salamo 3alaikom,

In order to make vim/vi behave in a certain manner you must specify those behaviours in vimrc file. That file should be stored /usr/share/vim for those changes to be global. The file should be stored as .vimrc -do you see the "." before the vimrc in the second case?- in your home directory. You can store that file in /etc/skel in order to let this file be included for every user that would be created onwards on your system. About the backspace behaviour reading the help in Vim will solve many of your problems. Tip: if you the lazy one, why don't you just copy the vimrc from Redhat vim to slack vim?

Salam.

alaa
why don't you change the symlink to vim if you don't like elvis???