Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Solved this problem in my Ubuntu box by installing Vim. I keep having this problem in every linux box I use. But I keep installing vim (over the existing vi)

The problem is, I can't get that "INSERT" sign at the bottom. The cursor is a black box and not a underscore-looking dash. When I backspace, it just goes over the text. Then when I type something new, the text starts getting replaced one by one. I hope you got it.

----------

I'm changing the question!

:set showmode gave me the "INSERT" mode. But still, when I backspace, the cursor goes over the text and when I type, it starts getting replaced one-by-one.

Here's a video of my problem: http://www.youtube.com/watch?v=16f1nrepZsA

share|improve this question

migrated from stackoverflow.com Oct 26 '12 at 19:36

This question came from our site for professional and enthusiast programmers.

5  
Unless you are posting your question from the 80s or early 90s, vi is very often a symlink to vim. –  romainl Oct 26 '12 at 15:13
    
I don't think this question belongs to stackoverflow.<br> Questions here should be related to programming. stackoverflow.com/faq#questions –  xci13 Oct 26 '12 at 15:42
1  
@AdelQodmani, vi(m) questions are on topic for SO. –  Kristo Oct 26 '12 at 18:02
    
Oh, thanks a lot. Sorry about that then. –  xci13 Oct 26 '12 at 18:03
    
I've added a screencast. Its less than 1min. Can some experts please look into it? I've had this problem for ages. Its high time it gets solved. –  Sreejith Ramakrishnan Oct 26 '12 at 18:07

2 Answers 2

This backspace "problem" is merely vi compatible behavior; since vi is almost certainly a symbolic link to vim, the presence of a ~/.vimrc—even if it is an empty file—should automatically fix your backspace issue. If not, I recommend putting ":set nocompatible" in your ~/.vimrc or at least ":set cpoptions-=v"

See (the single-quotes are meant to be part of the command):

:help 'compatible'
:help 'cpoptions'
share|improve this answer

1) the "INPUT MODE" or "INSERT" indicator can be switched on by "set showmode". You can put that in your ".exrc" file in your homefolder to make it the default. If the showmode is not switched on you're still in insert mode if you hit "i". It's just not shown.

2) typing backspace in command mode is like moving the cursor from right to left. It's the intented behaviour. To actually delete characters type "x" or "X".

share|improve this answer
    
I tried "set showmode" and now I'm seeing the "Insert". But, I still can't backspace while in INSERT mode. The same thing (cursor goes text) occurs. Anyway to resolve this? –  Sreejith Ramakrishnan Oct 26 '12 at 16:11
    
@pitseeker is correct. The backspace behavior your are experiencing is correct for vi. I would highly recommend installing vim because backspaces issues are nothing compared to one level of undo. –  Peter Rincker Oct 26 '12 at 18:33

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.