formate.config
¶
Read and parse formate configuration.
Data:
Invariant |
Functions:
|
Load the |
|
Returns a read-only view on the global configuration mapping, for hooks to do with as they wish. |
|
Given a mapping parsed from a TOML file (or similar), return a list of hooks selected by the user. |
|
Decorator to indicate to |
|
Decorator to indicate to |
-
_C_str
= TypeVar(_C_str, bound=typing.Callable[..., str])¶ Type:
TypeVar
Invariant
TypeVar
bound totyping.Callable
[…,str
].
-
load_toml
(filename)[source]¶ Load the
formate
configuration mapping from the given TOML file.- Parameters
- Return type
-
parse_global_config
(config)[source]¶ Returns a read-only view on the global configuration mapping, for hooks to do with as they wish.
- Parameters
config (
Mapping
) – Theformate
configuration, parsed from a TOML file (or similar).- Return type
-
parse_hooks
(config)[source]¶ Given a mapping parsed from a TOML file (or similar), return a list of hooks selected by the user.