From 8ec562fe522a35e454634dbc96c8832f8bb2a1fb Mon Sep 17 00:00:00 2001 From: zeertzjq Date: Wed, 17 Sep 2025 10:13:59 +0800 Subject: [PATCH] vim-patch:684edc7: runtime(doc): mention generic log highlighter (#35812) https://github.com/vim/vim/commit/684edc7dceea2e5c4f840eb6465595b78459e2f1 Co-authored-by: Christian Brabandt --- runtime/doc/syntax.txt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/runtime/doc/syntax.txt b/runtime/doc/syntax.txt index 0df739c35b..f5483130af 100644 --- a/runtime/doc/syntax.txt +++ b/runtime/doc/syntax.txt @@ -1896,6 +1896,22 @@ set "lite_minlines" to the value you desire. Example: > :let lite_minlines = 200 +LOG *ft-log-syntax* + +Vim comes with a simplistic generic log syntax highlighter. Because the log +file format is so generic, highlighting is not enabled by default, since it +can be distracting. If you want to enable this, simply set the "log" filetype +manually: > + + :set ft=log + +To enable this automatically for "*.log" files, add the following to your +personal `filetype.vim` file (usually located in `~/.config/nvim/filetype.vim` +on Unix, see also |new-filetype|): > + + augroup filetypedetect + au! BufNewFile,BufRead *.log setfiletype log + augroup END LPC *ft-lpc-syntax*