After porting to KConfigXT settings some time ago, there was still an
inefficient and error-prone codepath between the `RuleBook` (which keeps
the runtime list of `Rules`) and the `RuleBookSettings` (responsible for
config reads and saves), in the form of the `setRules()` method.
We can eliminate the `setRules()` codepath, reducing unnecessary
runtime process and file access operations, and instead:
- Keep track of the config `id` in the `Rules` objects
- Keep a single `RuleBookSettings` object as a member
- Modify or delete the discarded rules settings directly
- Save when necessary
This also fixes two bugs/pitfalls of the previous solution:
- the config group id for each rule is now preserved instead of creating
new ones
- no leftovers on the config file for the discarded groups and entries
Setting custom configs for the integration tests still works unchanged.
BUG: 446381
FIXED-IN: 6.1