syntax: xml: recognize an XML file also by its first line

Some .rdf files are XML, but the .rdf extension seems to be used
also for other things.  So... use the 'header' mechanism.
master
Benno Schulenberg 2017-05-07 19:49:58 +02:00
parent da67883508
commit a3102cd4cf
1 changed files with 1 additions and 0 deletions

View File

@ -1,6 +1,7 @@
## Here is an example for XML files.
syntax "xml" "\.([jrsx]html?|jnlp|mml|pom|rng|sgml?|svg|w[as]dl|wsdd|xjb|xml|xs(d|lt?)|xul)$"
header "<\?xml.*version=.*\?>"
magic "(XML|SGML) (sub)?document text"
comment "<!--|-->"