There are some places in HA yaml config which accepts “*” to define patterns.
For instance:
customize_glob:
sensor.temperature_*
This example defines an icon for all corr. helpers:
input_boolean:
customize_glob_1:
customize_glob_2:
customize_glob_3:
customize_glob_4:
customize_glob_5:
customize_glob_6:
homeassistant:
customize_glob:
input_boolean.customize_glob*:
icon: mdi:car
But this does not seem like a “true” regex.
For instance, this does not work:
input_boolean.customize_glob.*:
But this works:
input_boolean.customize_glob*[1,5]:
and changes an icon for entities “_1” & “_5”.
This also does not work:
/input_boolean.customize_glob.*[1,5]/:
So, seems that for this particular “customize_glob” option regex are not supported (and they are not mentioned in Docs).
But in Recorder docs regex are mentioned:
Has anyone defined “true” regex in Recoder config?
Or may be in “recorder.purge_entities” service (exactly where regex are mentioned in Docs).
Tested it myself with recorder settings & do not think regex is supported here…
This code
exclude:
entity_globs:
- input_boolean.test_*
excludes all entities starting with “input_boolean.test_”, but not with “input_boolean.testing_” (i.e. the code does work) - but “test_*” is not a regex.
Does this mean that:
– either regex is mentioned in Recorder docs by mistake,
– or regex is only supported for “recorder.purge_entities” service,
– or THIS is also “some kind of regex” ? )))