config: add note

The core purpose of `Prepare_config()` is to prepare the config by setting
defaults where not specified. It should not be involved itself in
validation of user options.

This can be an important distinction, for instance in `clean` where we
use this function, but avoid validation to potentially allow for an option
that deletes the config, that should work even in the face of an invalid
config.

Gbp-Dch: Ignore
This commit is contained in:
Lyndon Brown 2020-05-04 16:16:00 +01:00
parent 89ed6a54a1
commit 9d7393bbdb
1 changed files with 3 additions and 0 deletions

View File

@ -10,6 +10,9 @@
# Prepare config for use, filling in defaults where no value provided for instance
#
# This function should avoid performing validation checks and failing from invalid values.
# Validation should be done through `Validate_config()`.
Prepare_config ()
{
# Colouring is re-evaluated here just incase a hard coded override was given in the saved config