2 " Language: grub(8) configuration file
3 " Maintainer: Nikolai Weibull <now@bitwi.se>
4 " Latest Revision: 2006-04-19
6 if exists("b:current_syntax")
13 syn keyword grubTodo contained TODO FIXME XXX NOTE
15 syn region grubComment display oneline start='^#' end='$'
16 \ contains=grubTodo,@Spell
18 syn match grubDevice display
19 \ '(\([fh]d\d\|\d\+\|0x\x\+\)\(,\d\+\)\=\(,\l\)\=)'
21 syn match grubBlock display '\(\d\+\)\=+\d\+\(,\(\d\+\)\=+\d\+\)*'
23 syn match grubNumbers display '+\=\<\d\+\|0x\x\+\>'
25 syn match grubBegin display '^'
26 \ nextgroup=@grubCommands,grubComment skipwhite
28 syn cluster grubCommands contains=grubCommand,grubTitleCommand
30 syn keyword grubCommand contained default fallback hiddenmenu timeout
32 syn keyword grubTitleCommand contained title nextgroup=grubTitle skipwhite
34 syn match grubTitle contained display '.*'
36 syn keyword grubCommand contained bootp color device dhcp hide ifconfig
37 \ pager partnew parttype password rarp serial setkey
38 \ terminal tftpserver unhide blocklist boot cat
39 \ chainloader cmp configfile debug displayapm
40 \ displaymem embed find fstest geometry halt help
41 \ impsprobe initrd install ioprobe kernel lock
42 \ makeactive map md5crypt module modulenounzip pause
43 \ quit reboot read root rootnoverify savedefault setup
44 \ testload testvbe uppermem vbeprobe
46 syn keyword grubSpecial saved
48 syn match grubBlink display 'blink-'
49 syn keyword grubBlack black
50 syn keyword grubBlue blue
51 syn keyword grubGreen green
52 syn keyword grubRed red
53 syn keyword grubMagenta magenta
54 syn keyword grubBrown brown yellow
55 syn keyword grubWhite white
56 syn match grubLightGray display 'light-gray'
57 syn match grubLightBlue display 'light-blue'
58 syn match grubLightGreen display 'light-green'
59 syn match grubLightCyan display 'light-cyan'
60 syn match grubLightRed display 'light-red'
61 syn match grubLightMagenta display 'light-magenta'
62 syn match grubDarkGray display 'dark-gray'
64 hi def link grubComment Comment
65 hi def link grubTodo Todo
66 hi def link grubNumbers Number
67 hi def link grubDevice Identifier
68 hi def link grubBlock Identifier
69 hi def link grubCommand Keyword
70 hi def link grubTitleCommand grubCommand
71 hi def link grubTitle String
72 hi def link grubSpecial Special
74 hi def grubBlink cterm=inverse
75 hi def grubBlack ctermfg=Black ctermbg=White guifg=Black guibg=White
76 hi def grubBlue ctermfg=DarkBlue guifg=DarkBlue
77 hi def grubGreen ctermfg=DarkGreen guifg=DarkGreen
78 hi def grubRed ctermfg=DarkRed guifg=DarkRed
79 hi def grubMagenta ctermfg=DarkMagenta guifg=DarkMagenta
80 hi def grubBrown ctermfg=Brown guifg=Brown
81 hi def grubWhite ctermfg=White ctermbg=Black guifg=White guibg=Black
82 hi def grubLightGray ctermfg=LightGray guifg=LightGray
83 hi def grubLightBlue ctermfg=LightBlue guifg=LightBlue
84 hi def grubLightGreen ctermfg=LightGreen guifg=LightGreen
85 hi def grubLightCyan ctermfg=LightCyan guifg=LightCyan
86 hi def grubLightRed ctermfg=LightRed guifg=LightRed
87 hi def grubLightMagenta ctermfg=LightMagenta guifg=LightMagenta
88 hi def grubDarkGray ctermfg=DarkGray guifg=DarkGray
90 let b:current_syntax = "grub"