]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Improve summary output a bit
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Tue, 17 Dec 2024 11:36:59 +0000 (12:36 +0100)
committerJörg Behrmann <behrmann@physik.fu-berlin.de>
Wed, 18 Dec 2024 09:42:17 +0000 (10:42 +0100)
Let's skip a few sections for subimages as these will always be identical
to the main image anyways.

mkosi/config.py

index fc4e92e7d01065739e62313c2af3869b76a258a7..39fb5f1bf38ac2879c180be041ed3ae542d5939a 100644 (file)
@@ -4734,6 +4734,10 @@ def summary(config: Config) -> str:
 
     summary = f"""\
 {bold(f"IMAGE: {config.image or 'default'}")}
+"""
+
+    if not config.image:
+        summary += f"""\
 
     {bold("CONFIG")}:
                            Profiles: {line_join_list(config.profiles)}
@@ -4751,6 +4755,9 @@ def summary(config: Config) -> str:
            Repo Signature/Key check: {yes_no(config.repository_key_check)}
               Fetch Repository Keys: {yes_no(config.repository_key_fetch)}
                        Repositories: {line_join_list(config.repositories)}
+"""
+
+    summary += f"""\
 
     {bold("OUTPUT")}:
                       Output Format: {config.output_format}
@@ -4861,7 +4868,8 @@ def summary(config: Config) -> str:
                             GPG Key: ({"default" if config.key is None else config.key})
 """
 
-    summary += f"""\
+    if not config.image:
+        summary += f"""\
 
     {bold("BUILD CONFIGURATION")}:
                          Tools Tree: {config.tools_tree}