From: Jörg Behrmann Date: Tue, 14 May 2024 13:20:35 +0000 (+0200) Subject: Don't die when images already exist X-Git-Tag: v23.1~54 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6546ce778401f9f9f6f44c498e04ee64b86f6ccf;p=thirdparty%2Fmkosi.git Don't die when images already exist We already check whether outputs exist when looping over all image configs and skip the build if the output exists. This way one can just "mkosi build" after adding a new image and the missing ones will be built. --- diff --git a/mkosi/__init__.py b/mkosi/__init__.py index ff530538c..945975ebb 100644 --- a/mkosi/__init__.py +++ b/mkosi/__init__.py @@ -2695,7 +2695,7 @@ def check_outputs(config: Config) -> None: config.output_nspawn_settings if config.nspawn_settings else None, ): if f and (config.output_dir_or_cwd() / f).exists(): - die(f"Output path {f} exists already. (Consider invocation with --force.)") + logging.info(f"Output path {f} exists already. (Use --force to rebuild.)") def check_tool(config: Config, *tools: PathString, reason: str, hint: Optional[str] = None) -> Path: