neovim

Neovim text editor
git clone https://git.dasho.dev/neovim.git
Log | Files | Refs | README

viminfo.vim (1307B)


      1 " Vim syntax file
      2 " Language:	Vim .viminfo file
      3 " Maintainer:	The Vim Project <https://github.com/vim/vim>
      4 " Last Change:	2023 Aug 10
      5 " Former Maintainer:	Bram Moolenaar <Bram@vim.org>
      6 
      7 " Quit when a (custom) syntax file was already loaded
      8 if exists("b:current_syntax")
      9  finish
     10 endif
     11 
     12 let s:cpo_save = &cpo
     13 set cpo&vim
     14 
     15 " The lines that are NOT recognized
     16 syn match viminfoError "^[^\t].*"
     17 
     18 " The one-character one-liners that are recognized
     19 syn match viminfoStatement "^[/&$@:?=%!<]"
     20 
     21 " The two-character one-liners that are recognized
     22 syn match viminfoStatement "^[-'>"]."
     23 syn match viminfoStatement +^"".+
     24 syn match viminfoStatement "^\~[/&]"
     25 syn match viminfoStatement "^\~[hH]"
     26 syn match viminfoStatement "^\~[mM][sS][lL][eE]\d\+\~\=[/&]"
     27 
     28 syn match viminfoOption "^\*.*=" contains=viminfoOptionName
     29 syn match viminfoOptionName "\*\a*"ms=s+1 contained
     30 
     31 " Comments
     32 syn match viminfoComment "^#.*"
     33 
     34 " New style lines.  TODO: highlight numbers and strings.
     35 syn match viminfoNew "^|.*"
     36 
     37 " Define the default highlighting.
     38 " Only used when an item doesn't have highlighting yet
     39 hi def link viminfoComment	Comment
     40 hi def link viminfoError	Error
     41 hi def link viminfoStatement	Statement
     42 hi def link viminfoNew		String
     43 
     44 let b:current_syntax = "viminfo"
     45 
     46 let &cpo = s:cpo_save
     47 unlet s:cpo_save
     48 
     49 " vim: ts=8 sw=2