From 4b3fab14dbde971f15d8783e9ef125b19fdbc829 Mon Sep 17 00:00:00 2001 From: Colin Caine Date: Thu, 18 Apr 2024 23:53:02 +0200 Subject: patch 9.1.0354: runtime(uci): No support for uci file types Problem: runtime(uci): No support for uci file types (Wu, Zhenyu) Solution: include basic uci ftplugin and syntax plugins (Colin Caine) closes: #14575 Co-authored-by: Wu, Zhenyu Signed-off-by: Colin Caine Signed-off-by: Christian Brabandt --- runtime/filetype.vim | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'runtime/filetype.vim') diff --git a/runtime/filetype.vim b/runtime/filetype.vim index 4a877f7f84..c7fc331963 100644 --- a/runtime/filetype.vim +++ b/runtime/filetype.vim @@ -3030,6 +3030,12 @@ au BufNewFile,BufRead {.,}tmux*.conf* setf tmux " Universal Scene Description au BufNewFile,BufRead *.usda,*.usd setf usd +" UCI +" UCI files are normally in /etc/config, but that might be mounted over sshfs or similar, so we match more loosely. +" There was some concern[1] that this pattern would match too much, so now we check the file content as well. +" [1]: https://github.com/vim/vim/pull/14385#discussion_r1558878741 +au BufNewFile,BufRead */etc/config/* if dist#ft#Detect_UCI_statements() | call s:StarSetf('uci') | endif + " VHDL au BufNewFile,BufRead *.vhdl_[0-9]* call s:StarSetf('vhdl') -- cgit v1.2.3