Problem: Yaml files are only recognized by the file extension.
Solution: Check for a line starting with "%YAML". (Jason Franklin)
elseif s:line1 =~? '-\*-.*erlang.*-\*-'
set ft=erlang
+ " YAML
+ elseif s:line1 =~# '^%YAML'
+ set ft=yaml
+
" CVS diff
else
let s:lnum = 1
\ 'haskell': [['#!/path/haskell']],
\ 'cpp': [['// Standard iostream objects -*- C++ -*-'],
\ ['// -*- C++ -*-']],
+ \ 'yaml': [['%YAML 1.2']],
\ }
func Test_script_detection()
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 360,
/**/
359,
/**/