return cast(str, namespace["distribution"].default_release())
-def config_default_tools_tree(namespace: dict[str, Any]) -> Optional[Path]:
- if namespace.get("image") != "main":
- return None
-
- configdir = finalize_configdir(namespace["directory"])
- return Path("default") if configdir and (configdir / "mkosi.tools.conf").exists() else None
-
-
def config_default_tools_tree_distribution(namespace: dict[str, Any]) -> Distribution:
if d := os.getenv("MKOSI_HOST_DISTRIBUTION"):
return Distribution(d).default_tools_tree_distribution()
section="Build",
parse=config_make_path_parser(constants=("default",)),
path_suffixes=("tools",),
- default_factory=config_default_tools_tree,
help="Look up programs to execute inside the given tree",
scope=SettingScope.universal,
),
using the settings below or with `mkosi.tools.conf` which can either be a
file or directory containing extra configuration for the default tools tree.
- If `mkosi.tools.conf` exists in the directory mkosi is invoked in,
- a default tools tree is used if no tools tree is specified.
-
The following table shows for which distributions default tools tree
packages are defined and which packages are included in those default
tools trees: