vim script for a debian sources.list

Bram Moolenaar Bram at moolenaar.net
Tue Mar 28 08:12:22 UTC 2006


Matthijs -

> I've written a script that highlights the sources.list in Debian. I
> would like it if it could be included into the vim 7 release. The files
> only exists in two places:
> /etc/apt/sources.list and
> /etc/apt/sources.list.d/*
> 
> The script is attached on this mail.
> 
> Thanks for considering to include this script.

Yes, I can include this.  But first a few remarks.

The filetype is "debsources", therefore all the items in the syntax file
should start with that, not "sources".  To keep it consistent.

The use of HiLink for backwards compatibility with Vim 5.x isn't all
that relevant now.  You can use "hi def link" to keep it simple.  I have
done that for the C syntax file as well.

> " deb-src is a keyword
> setlocal iskeyword+=-

It appears you hardly use the '-' in a keyword though.  You could also
use a match to avoid changing 'iskeyword' from what a user expects.

Aren't there ANY other files in the /etc/apt/sources.list.d/ directory?

- Bram

-- 
GUARD #1:  What -- a swallow carrying a coconut?
ARTHUR:    It could grip it by the husk!
GUARD #1:  It's not a question of where he grips it!  It's a simple question
           of weight ratios!  A five ounce bird could not carry a 1 pound
           coconut.
                                  The Quest for the Holy Grail (Monty Python)

 /// Bram Moolenaar -- Bram at Moolenaar.net -- http://www.Moolenaar.net   \\\
///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\        download, build and distribute -- http://www.A-A-P.org        ///
 \\\            help me help AIDS victims -- http://www.ICCF.nl         ///



More information about the pkg-vim-maintainers mailing list