Quantcast

syntax file for multilog

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

syntax file for multilog

Jorge Almeida
I noticed that log files produced by multilog are colored when opened
with vim. This happens with "saved" files (with names like
@4000000042b2ecc214904e1c.s) but not with the current file (named, you
guessed, "current"). So I assume that vim knows what to do based on the
suffix ".s". Now, in /usr/share/vim/vim63/syntax/ there is no such thing
as a file named s.vim (I'm using gentoo linux, BTW). On the other hand,
the file named "current" is the one for which color syntax would be more
usefull.
Anyone knows where this coloring came from? And can I force vim to use
it with "current"?

--
Jorge Almeida
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: syntax file for multilog

Kyle Wheeler
On Friday, June 17 at 04:44 PM, quoth Jorge Almeida:

> I noticed that log files produced by multilog are colored when opened
> with vim. This happens with "saved" files (with names like
> @4000000042b2ecc214904e1c.s) but not with the current file (named, you
> guessed, "current"). So I assume that vim knows what to do based on the
> suffix ".s". Now, in /usr/share/vim/vim63/syntax/ there is no such thing
> as a file named s.vim (I'm using gentoo linux, BTW). On the other hand,
> the file named "current" is the one for which color syntax would be more
> usefull.
> Anyone knows where this coloring came from? And can I force vim to use
> it with "current"?
HEH. :)

The syntax coloring is assembler coloring (run ":echo &ft" to check for
yourself, "asm" comes from "Assembler Source Language"). No idea why vim
guessed assembler for those files. Probably something to do with
beginning with an @ symbol.

You can force vim to think all files named "current" are assembler files
by adding the following to your ~/.vimrc:

    autocmd BufEnter current set ft=asm

~Kyle
--
There is no more evil thing in this world than race prejudice . . . It
justifies and holds together more baseness, cruelty, and abomination
than any other sort of error in the world.
-- H. G. Wells

signature.asc (203 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: syntax file for multilog

Jorge Almeida
On Fri, 17 Jun 2005, Kyle Wheeler wrote:

>
> The syntax coloring is assembler coloring (run ":echo &ft" to check for
> yourself, "asm" comes from "Assembler Source Language"). No idea why vim
> guessed assembler for those files. Probably something to do with beginning
> with an @ symbol.
Nope. I copied current to @current, and no difference.
>
> You can force vim to think all files named "current" are assembler files by
> adding the following to your ~/.vimrc:
>
>   autocmd BufEnter current set ft=asm
>
Done.

Thanks.

Jorge
Loading...