LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
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 12-17-2004, 02:34 PM   #1
donniejones18
LQ Newbie
 
Registered: Jun 2001
Posts: 21

Rep: Reputation: 15
vim syntax highlighting problems.


Hello,

I am trying to get vim syntax highlighting to work, but I am having some problems...
I first tried putting "syntax on" in my ~/.vimrc file, and then opening a .c source code
file to see the syntax highlighting, but there is no color. I have mutt and other things loading in my xterm that are in color, so it seems that my xterm supports color just fine.

I then tried typing ":syntax on" in vim, and I received this error:
Error detected while processing /usr/share/vim/vim63/syntax/syntax.vim:
line 42:
E216: No such group or event: filetypedetect BufRead

I was not able to find any results for this error on google...
I am using debian "testing" branch and vim version 6.3.13
dpkg -l | grep vim
ii vim 6.3-013+2 Vi IMproved - enhanced vi editor
ii vim-common 6.3-013+2 Vi IMproved - Common files

Any help would be great...
Thank you.
__
Donnie
 
Old 12-17-2004, 04:06 PM   #2
mhiggins
Member
 
Registered: Feb 2004
Posts: 140

Rep: Reputation: 15
make sure you have

/usr/share/vim/vim63/syntax
and that there is a c.vim file in that dir
 
Old 12-17-2004, 08:20 PM   #3
donniejones18
LQ Newbie
 
Registered: Jun 2001
Posts: 21

Original Poster
Rep: Reputation: 15
Yes, I have the file /usr/share/vim/vim63/syntax/c.vim
 
Old 01-17-2006, 09:15 AM   #4
atrixnet
LQ Newbie
 
Registered: Jan 2006
Posts: 5

Rep: Reputation: 0
Lightbulb

Fix: re-install

The jist of it is to re-install vim. I saw this mentioned in an obscure IRC log archive and subsequently tried it myself. I can confirm that the re-install solution worked for me.

How to fix the problem on Debian:

sudo apt-get update ; sudo apt-get remove --purge vim vim-common vim-full vim-scripts ; sudo apt-get clean ; sudo apt-get install vim vim-common vim-full vim-scripts

If you aren't using Debian:

You should be. Ha ha.

--
Tommy Butler
Dot Simple, LLC
 
Old 01-17-2006, 09:18 AM   #5
donniejones18
LQ Newbie
 
Registered: Jun 2001
Posts: 21

Original Poster
Rep: Reputation: 15
Thanks for the reply.

I believe this problem was later fixed by an "apt-get upgrade" that replaced the old files...
 
Old 01-18-2006, 12:19 PM   #6
atrixnet
LQ Newbie
 
Registered: Jan 2006
Posts: 5

Rep: Reputation: 0
Quote:
Originally Posted by donniejones18
Thanks for the reply.

I believe this problem was later fixed by an "apt-get upgrade" that replaced the old files...
nope. not yet.
 
Old 01-18-2006, 12:22 PM   #7
atrixnet
LQ Newbie
 
Registered: Jan 2006
Posts: 5

Rep: Reputation: 0
oh and by the way...

the fix won't work if you have KDE installed on your machine unless you uninstall KDE as well. I'm working on a fix for that myself, and I may write a patch if there's any interest.

--
Tommy Butler
Dot Simple, LLC
www dot dotsimple dotcom
 
Old 04-16-2006, 08:03 PM   #8
moon.id
LQ Newbie
 
Registered: Apr 2006
Posts: 1

Rep: Reputation: 0
Lightbulb

Another Fix:

Edit the "runtimepath" variable in '/etc/vim/vimrc' to include '/usr/share/vim/vim63' or '.../vim64' according the the version installed by you.

Ref:
lists.alioth.debian.org/pipermail/pkg-vim-maintainers/2005-October/001327.html
Enjoy

- Mohan
 
  


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
RdHat Vim Syntax Highlighting R4z0r Linux - Software 8 09-06-2011 01:22 PM
vim syntax highlighting MiniMe001 Linux - General 2 06-19-2005 11:08 AM
Adding Syntax Highlighting to VIM TastyWheat Linux - Software 2 02-27-2004 03:37 AM
How to make vim has syntax highlighting ICO Linux - General 4 01-05-2004 10:35 AM
Vim syntax highlighting NSKL Linux - Software 2 11-09-2002 02:39 AM


All times are GMT -5. The time now is 03:15 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration