mirror of
https://github.com/Icinga/icinga2.git
synced 2025-07-31 01:24:19 +02:00
parent
af906e2b8b
commit
ff0c44d435
@ -325,12 +325,13 @@ to obtain the Vim configuration, please install the extra package `vim-icinga2`.
|
|||||||
|
|
||||||
### <a id="configuration-syntax-highlighting-vim"></a> Configuration Syntax Highlighting using Vim
|
### <a id="configuration-syntax-highlighting-vim"></a> Configuration Syntax Highlighting using Vim
|
||||||
|
|
||||||
Install the package vim-icinga2 with your distribution's package manager.
|
Install the package `vim-icinga2` with your distribution's package manager.
|
||||||
|
|
||||||
Debian/Ubuntu:
|
Debian/Ubuntu:
|
||||||
|
|
||||||
$ apt-get install vim-icinga2 vim-addon-manager
|
$ apt-get install vim-icinga2 vim-addon-manager
|
||||||
$ vim-addon-manager -w install icinga2
|
$ vim-addon-manager -w install icinga2
|
||||||
|
Info: installing removed addon 'icinga2' to /var/lib/vim/addons
|
||||||
|
|
||||||
RHEL/CentOS/Fedora:
|
RHEL/CentOS/Fedora:
|
||||||
|
|
||||||
@ -340,6 +341,12 @@ SLES/openSUSE:
|
|||||||
|
|
||||||
$ zypper install vim-icinga2
|
$ zypper install vim-icinga2
|
||||||
|
|
||||||
|
Ensure that syntax highlighting is enabled e.g. by editing the user's `vimrc`
|
||||||
|
configuration file:
|
||||||
|
|
||||||
|
$ vim ~/.vimrc
|
||||||
|
syntax on
|
||||||
|
|
||||||
Test it:
|
Test it:
|
||||||
|
|
||||||
$ vim /etc/icinga2/conf.d/templates.conf
|
$ vim /etc/icinga2/conf.d/templates.conf
|
||||||
@ -349,10 +356,11 @@ Test it:
|
|||||||
|
|
||||||
### <a id="configuration-syntax-highlighting-nano"></a> Configuration Syntax Highlighting using Nano
|
### <a id="configuration-syntax-highlighting-nano"></a> Configuration Syntax Highlighting using Nano
|
||||||
|
|
||||||
Install the package nano-icinga2 with your distribution's package manager.
|
Install the package `nano-icinga2` with your distribution's package manager.
|
||||||
|
|
||||||
**Note:** On Debian and Ubuntu the syntax files are installed with the `icinga2-common` package, and
|
Debian/Ubuntu:
|
||||||
enabled by default.
|
|
||||||
|
**Note:** The syntax files are installed with the `icinga2-common` package already.
|
||||||
|
|
||||||
RHEL/CentOS/Fedora:
|
RHEL/CentOS/Fedora:
|
||||||
|
|
||||||
@ -362,10 +370,12 @@ SLES/openSUSE:
|
|||||||
|
|
||||||
$ zypper install nano-icinga2
|
$ zypper install nano-icinga2
|
||||||
|
|
||||||
In addition, for RPM based systems, make sure to enable the syntax extension, by copying the `/etc/nanorc`
|
Copy the `/etc/nanorc` sample file to your home directory.
|
||||||
sample file to your home directory. And including the `icinga2.nanorc` file.
|
|
||||||
|
|
||||||
$ cp /etc/nanorc ~/.nanorc
|
$ cp /etc/nanorc ~/.nanorc
|
||||||
|
|
||||||
|
Include the `icinga2.nanorc` file.
|
||||||
|
|
||||||
$ vim ~/.nanorc
|
$ vim ~/.nanorc
|
||||||
|
|
||||||
## Icinga 2
|
## Icinga 2
|
||||||
|
Loading…
x
Reference in New Issue
Block a user