← Back to team overview

curtin-dev team mailing list archive

Re: [Merge] ~dbungert/curtin:resize into curtin:master

 

Review: Approve

All this looks great, thanks.

Diff comments:

> diff --git a/curtin/storage_config.py b/curtin/storage_config.py
> index e9a8fdd..2ede996 100644
> --- a/curtin/storage_config.py
> +++ b/curtin/storage_config.py
> @@ -1357,4 +1357,12 @@ def extract_storage_config(probe_data, strict=False):
>      return {'storage': merged_config}
>  
>  
> +def select_configs(storage_config, **kwargs):

Nice, I bet there are approximately 1 billion places we could use this function.

> +    """ Given a set of key=value arguments, return a list of the configs that
> +        match all specified key-value pairs.
> +    """
> +    return [cfg for cfg in storage_config.values()
> +            if all(cfg.get(k) == v for k, v in kwargs.items())]
> +
> +
>  # vi: ts=4 expandtab syntax=python


-- 
https://code.launchpad.net/~dbungert/curtin/+git/curtin/+merge/417829
Your team curtin developers is subscribed to branch curtin:master.



References