Loading ...
Sorry, an error occurred while loading the content.
 

Re: how to control the syntax hightlighting style?

Expand Messages
  • Benji Fisher
    ... What version of Vim are you using, and what is the exact filename? When I do ... with Vim 5.7, vim(*) knows to strip off the .bak and set the filetype
    Message 1 of 3 , Jun 4, 2001
      Liu Wen wrote:
      >
      > for example , an C program file ending in .bak, so vi would not
      > highlight it. can I force it to ?

      What version of Vim are you using, and what is the exact filename?
      When I do

      :e foo.c.bak

      with Vim 5.7, vim(*) knows to strip off the ".bak" and set the filetype
      (and syntax) as it would for foo.c . In other words, I get C syntax
      highlighting. This does not work with foo_c.bak, for example, or foo.bak
      .

      --Benji Fisher

      (*) It is not the vim program itself, but the script
      $VIMRUNTIME/filetype.vim that does this processing. Have a look!
    Your message has been successfully submitted and would be delivered to recipients shortly.