Files
icinga2/icinga2-vim_syntax.patch
Eric Schirra b55017e930 - Update to 2.14.3
- Security: fix TLS certificate validation bypass. CVE-2024-49369
   - Security: update OpenSSL shipped on Windows to v3.0.15.
   - Windows: sign MSI packages with a certificate the OS trusts by default.
- Revision and cleanup of the spec file to remove errors and make it clearer.

OBS-URL: https://build.opensuse.org/package/show/server:monitoring/icinga2?expand=0&rev=188
2024-11-13 10:21:45 +00:00

41 lines
1.3 KiB
Diff

#
# vim > 8.2 produces the following error output below, if not set into
# nocompatibility mode.
#
# Error detected while processing /usr/share/vim/vim82/suse.vimrc[10]..
# /usr/share/vim/vim82/syntax/syntax.vim[43]..
# BufRead Autocommands for "/*etc/icinga2/*.conf"..
# FileType Autocommands for "*"..Syntax
# Autocommands for "*"..function <SNR>3_SynSet[25]..
# script /usr/share/vim/site/syntax/icinga2.vim:
# line [...]:
# E10: \ should be followed by /, ? or &
#
# The patch below is a quick workaround, stolen from:
# https://trac.nginx.org/nginx/attachment/ticket/2276/fix-nginx-syntax.patch
#
Index: icinga2-2.14.3/tools/syntax/vim/syntax/icinga2.vim
===================================================================
--- icinga2-2.14.3.orig/tools/syntax/vim/syntax/icinga2.vim
+++ icinga2-2.14.3/tools/syntax/vim/syntax/icinga2.vim
@@ -16,6 +16,10 @@ if !exists("main_syntax")
let main_syntax = 'icinga2'
endif
+" Reset compatible-options to Vim default value, just in case:
+let s:save_cpo = &cpo
+set cpo&vim
+
" case off
syntax case ignore
@@ -359,3 +363,7 @@ hi link icinga2Namespace Statement
hi link valueNumber Number
hi link valueBoolean Boolean
hi link valueNull Special
+
+" Restore current compatible-options:
+let &cpo = s:save_cpo
+unlet s:save_cpo