LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-20-2004, 10:36 AM   #1
uveraser
Member
 
Registered: Dec 2003
Location: Tavistock, Devon, England
Distribution: Slackware 9.1, LFS 5.0, Mandrake 9.0/9.1/10.0, Knoppix 3.1, Windows 98SE, Windows XP Pro
Posts: 37

Rep: Reputation: 15
VIM Setup- No 'insert' mode


My text editor of choice is VIM. In Mandrake it worked fine out of the box, but I have just installed Slackware and there is one major problem: I cannot properly edit text. Considering you can't really edit any config files without one, a working text editor could be quite useful (I would have thought that both the developers of slackware and vim would have made sure it worked properly on install). I have read the first few lines of the 'getting started' section of the vim manual and failed on the first hurdle. It says press 'i' to switch from normal mode to insert mode. Pressing 'i' does nothing. In mandrake the insert key worked as well and '--INSERT--' or '--REPLACE--' would appear in white in the lower left of the screen. The insert key also does nothing- in fact, I have pressed every key on the keyboard and cannot enter insert mode.

Please help- I cannot really setup anything else until this is fixed.
Simon
 
Old 05-25-2004, 10:44 AM   #2
uveraser
Member
 
Registered: Dec 2003
Location: Tavistock, Devon, England
Distribution: Slackware 9.1, LFS 5.0, Mandrake 9.0/9.1/10.0, Knoppix 3.1, Windows 98SE, Windows XP Pro
Posts: 37

Original Poster
Rep: Reputation: 15
OK, in case anybody else has the same problem here is the solution I found:
Since version 5.0, VIM runs in Vi compatible mode by default, unless you have a '.vimrc' file in your home directory. There are other exceptions (see the VIM readme), so for simplicity, create a '.vimrc' file in your home directory and add the following line:
set nocompatible
(to temporarily change the setting whilst VIM is running type ":set nocompatible" <enter>)

You will probably notice that even in nocompatible mode, backspace does not function as you would expect it to. To fix this, add the following line into your .vimrc file:
set backspace=2
(this is a short version of "set backspace=indent,eol,start")
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
VIM insert before a visual block... pld Linux - Software 0 06-22-2005 11:36 AM
arrow keys in vi insert mode sanjeev.naik Linux - Software 6 09-04-2004 12:21 PM
moving around in vim while in insert mode cleff Linux - Software 3 06-14-2004 10:26 PM
vim: coding mode and doc writing mode? miknight Linux - Software 2 03-07-2004 08:51 PM
insert mode in vim usr Linux - Software 1 01-18-2004 01:25 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 04:30 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration