annotate runtime/syntax/hgcommit.vim @ 34590:4cad34137ea0

runtime(vim): Update base-syntax, disallow '.' at start of menu item names (#14232) Commit: https://github.com/vim/vim/commit/ec21bafc135a1e78d40e4fc9118e022bbab958e8 Author: dkearns <dougkearns@gmail.com> Date: Wed Mar 20 04:04:42 2024 +1100 runtime(vim): Update base-syntax, disallow '.' at start of menu item names (https://github.com/vim/vim/issues/14232) Disallow '.' at the start of a menu item name. This is the menu path separator character and should be escaped with a '\' in this case. Partially fixes #14230. "popup" is still incorrectly matched as the Ex command. Signed-off-by: Doug Kearns <dougkearns@gmail.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
author Christian Brabandt <cb@256bit.org>
date Tue, 19 Mar 2024 18:15:05 +0100
parents 7d68a90cbf5c
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
3750
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
1 " Vim syntax file
31579
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
2 " Language: hg/sl (Mercurial / Sapling) commit file
3750
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
3 " Maintainer: Ken Takata <kentkt at csc dot jp>
31579
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
4 " Max Coplan <mchcopl@gmail.com>
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
5 " Last Change: 2022-12-08
3750
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
6 " License: VIM License
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
7 " URL: https://github.com/k-takata/hg-vim
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
8
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
9 if exists("b:current_syntax")
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
10 finish
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
11 endif
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
12
31579
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
13 syn match hgcommitComment "^\%(SL\|HG\): .*$" contains=@NoSpell
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
14 syn match hgcommitUser "^\%(SL\|HG\): user: \zs.*$" contains=@NoSpell contained containedin=hgcommitComment
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
15 syn match hgcommitBranch "^\%(SL\|HG\): branch \zs.*$" contains=@NoSpell contained containedin=hgcommitComment
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
16 syn match hgcommitAdded "^\%(SL\|HG\): \zsadded .*$" contains=@NoSpell contained containedin=hgcommitComment
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
17 syn match hgcommitChanged "^\%(SL\|HG\): \zschanged .*$" contains=@NoSpell contained containedin=hgcommitComment
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
18 syn match hgcommitRemoved "^\%(SL\|HG\): \zsremoved .*$" contains=@NoSpell contained containedin=hgcommitComment
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
19
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
20 syn region hgcommitDiff start=/\%(^\(SL\|HG\): diff --\%(git\|cc\|combined\) \)\@=/ end=/^\%(diff --\|$\|@@\@!\|[^[:alnum:]\ +-]\S\@!\)\@=/ fold contains=@hgcommitDiff
7d68a90cbf5c Update runtime files
Bram Moolenaar <Bram@vim.org>
parents: 3830
diff changeset
21 syn include @hgcommitDiff syntax/shared/hgcommitDiff.vim
3750
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
22
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
23 hi def link hgcommitComment Comment
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
24 hi def link hgcommitUser String
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
25 hi def link hgcommitBranch String
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
26 hi def link hgcommitAdded Identifier
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
27 hi def link hgcommitChanged Special
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
28 hi def link hgcommitRemoved Constant
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
29
536aa8b0c934 Update runtime files.
Bram Moolenaar <bram@vim.org>
parents:
diff changeset
30 let b:current_syntax = "hgcommit"