How to set up configuration files?

This post was flagged by the community and is temporarily hidden.

Hi @mohamed,

I don’t follow you. What do you mean by a “control file”?

openHAB/openHABian are Java based. If you use files to configure openHAB, those are text-based and don’t have a particular language associated with them. If you configure things via the Paper UI, your configurations are stored in a JSON file, which is just a specially formatted text file. JSON files have a Javascript origin, but in my book, I would not classify them as using a programming language.

If by control files, you mean, rules, then you have the following.

  • If you use the standard rules engine (Rules DSL), I believe the rules are based up Xtend.

  • If you are using the Next Generation Rules Engine (NGRE), your rules can be Python, Javascript, or Groovy based.


1 Like

hello Burzin ,
first of all , thank you for answering my question .
i meant " rules file ’ the file where we write our rules to control our devices .
for example , what is the programming language used in the following codes ?

The rules engine DSL (Domain Specific Language) is built with XTend. Afaik XTend itself is built with Java, so the openHAB rules DSL is near to (but not the same as) Java.
The domain specific part e.g. is support of Items, triggers and so on.

If posting code, please, whenever possible, use text instead of pictures. Use code fences to format code as code.

In the discourse forum software there is an issue which prevents the code fences buttons to be visible, but you can still use them (between date/time and gear symbol) or simply type three backticks before and after the code (nothing else in the line):

Your code goes here


This topic was automatically closed 41 days after the last reply. New replies are no longer allowed.