diff options
| author | Johannes Altmanninger <aclopte@gmail.com> | 2022-08-16 19:14:05 +0200 |
|---|---|---|
| committer | Johannes Altmanninger <aclopte@gmail.com> | 2022-09-10 07:35:29 +0200 |
| commit | 647e568d3b24936fae20af245b283755a712d62a (patch) | |
| tree | 391ea514035ae57cc8a73bb9499ba926baa64d42 /src/shared_string.cc | |
| parent | 1a8f379a43d8e60cf269dd86345c874f421b2385 (diff) | |
rc kakrc: add kak=kakrc highlighter alias for markdown/restructuredtext
Filetypes markdown and restructuredtext reuse highlighters from other
filetypes to highlight code blocks. For example, to highlight a code
block of language foo they essentially do
require-module foo
add-highlighter [...] ref foo
This works great if the module name matches the shared
highlighter. This is the case almost all scripts in rc/filetype*.
The only exception is kakrc.kak: the highlighter is named "kakrc"
(just like the filetype) but the module is named "kak".
This requires weird hacks in markdown/restructuredtext. Ideally we
could remove this inconsistency by renaming both the filetype and the
highlighter to "kak" but that's a breaking change. Until we do that,
let's add an alias so we can treat filetypes uniformly. This helps
the following commits, which otherwise would need to add ugly extra
code for kakrc highlighters.
The following commit will generalize this approach, allowing users
to add arbitrary aliases.
Diffstat (limited to 'src/shared_string.cc')
0 files changed, 0 insertions, 0 deletions
