comparison runtime/filetype.vim @ 34739:7de0133f87f3 v9.1.0248

patch 9.1.0248: filetype: yarn lock files are not recognized Commit: https://github.com/vim/vim/commit/3b497aa2470ff613fed79569bc8589dae8dc3190 Author: Wu, Zhenyu <wuzhenyu@ustc.edu> Date: Sun Mar 31 19:51:19 2024 +0200 patch 9.1.0248: filetype: yarn lock files are not recognized Problem: filetype: yarn lock files are not recognized Solution: Detect 'yarn.lock' files as yaml (Wu, Zhenyu) closes: #14369 Signed-off-by: Wu, Zhenyu <wuzhenyu@ustc.edu> Signed-off-by: Christian Brabandt <cb@256bit.org>
author Christian Brabandt <cb@256bit.org>
date Sun, 31 Mar 2024 20:00:05 +0200
parents 74cbeec9496a
children d51cc27a7bdf
comparison
equal deleted inserted replaced
34738:67d0b7bd2a4e 34739:7de0133f87f3
2957 \ || getline(3) =~ '^#' || getline(4) =~ '^#' 2957 \ || getline(3) =~ '^#' || getline(4) =~ '^#'
2958 \ || getline(5) =~ '^#') | 2958 \ || getline(5) =~ '^#') |
2959 \ setf FALLBACK conf | 2959 \ setf FALLBACK conf |
2960 \ endif 2960 \ endif
2961 2961
2962 " Yarn lock
2963 au BufNewFile,BufRead yarn.lock setf yaml
2964
2962 2965
2963 " If the GUI is already running, may still need to install the Syntax menu. 2966 " If the GUI is already running, may still need to install the Syntax menu.
2964 " Don't do it when the 'M' flag is included in 'guioptions'. 2967 " Don't do it when the 'M' flag is included in 'guioptions'.
2965 if has("menu") && has("gui_running") 2968 if has("menu") && has("gui_running")
2966 \ && !exists("did_install_syntax_menu") && &guioptions !~# "M" 2969 \ && !exists("did_install_syntax_menu") && &guioptions !~# "M"