Open oxzi opened 2 months ago
That's quite a bit of digging you've done there, thanks! Now it also made sense to my why I first wasn't able to reproduce this behavior on two very different systems with a Vim 9.1.:
default on, off when a vimrc or gvimrc file is found, reset in defaults.vim
As I had a .vimrc
laying around, it was always off.
However, in the current state, installing the vim-icinga2
package on a vanilla openSUSE Leap 15.5 system[^0] results in Vim errors when one tries to edit some Icinga 2 configuration file. Unless we want to add some documentation (which nobody is going to read) stating this corner case, I would continue with this suggested change as it allows using our syntax also within an enabled compatible
mode.
[^0]: Most probably also on older versions.
However, in the current state, installing the
vim-icinga2
package on a vanilla openSUSE Leap 15.5 system1 results in Vim errors when one tries to edit some Icinga 2 configuration file.
The error does not necessarily depend on the used vim version, but is a pure openSUSE
bug and exists in all supported versions.
" get easier to use and more user friendly vim defaults " CAUTION: This option breaks some vi compatibility. " Switch it off if you prefer real vi compatibility set nocompatible
I would continue with this suggested change as it allows using our syntax also within an enabled compatible mode.
There is no syntax highlighting support when using vim with compatible mode and openSUSE also starts vim with incompatible mode, the flag set nocompatible
just needs to be set before the syntax on
command. I actually want to report this to openSUSE, but I'm a little confused where to even start. You can do it if you are familiar with their bug reporting procedure.
There is no syntax highlighting support when using vim with compatible mode
Really? I don't think that this is the case and the documentation also doesn't state this.
For example, I have just launched vim -C commands.conf
, got a load of errors[^0], but afterwards a Vim with active syntax highlighting.
[^0]: Most from other plugins, which also don't like compatible
.
There occurs a Vim syntax error on a fresh openSUSE Leap 15.5 system when trying to edit the Icinga 2 configuration. The specific packages were vim-9.1.0330-150500.20.12.1.x86_64, vim-icinga2-2.14.2-1.x86_64 and the following error was shown:
ref/IP/53301