The correct way to verify the config (configuration check)

  • Platform information:
    • OS: Linux
    • Java Runtime Environment: 1.8.0_161
    • openHAB version: 2.2.0
  • Issue of the topic: The correct way to verify the config (/etc/openhab2).

How can I check the config?
Get information about:

  1. Syntax errors. That if I “lost” a comma or a bracket, how to find this place?
  2. Logical errors. That if I in “items” “contact” place parameters for the “switch”?
  3. Error in string of “bidings”. In MQTT the string becomes very long and complicated - it’s easy to lose a special character (sharp brackets or a colon) and make a mistake in the syntax.
  4. Incorrect structure. That if in “sitemap” inside the frame I specified one more frame (mistake copy-paste), how to learn about such error?
  5. Reference to the wrong name of the “items”. If “sitemap” indicates the old name, which is no longer in “items” list.
  6. how to check syntax “rule” (without run).

The best way would be to use VSCode to validate your syntax on all files.