]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
config: Don't load history if --directory "" is passed
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Wed, 19 Feb 2025 11:37:08 +0000 (12:37 +0100)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Wed, 19 Feb 2025 11:37:08 +0000 (12:37 +0100)
mkosi/config.py

index 1d959e9994434e39732eefb8a1157f3e3125974c..8fa2e4d5974b5d7c3a3cdbfcdddfda7c1a5bed6c 100644 (file)
@@ -4640,7 +4640,8 @@ class ParseContext:
 
 def have_history(args: Args) -> bool:
     return (
-        args.verb.needs_build()
+        args.directory is not None
+        and args.verb.needs_build()
         and args.verb != Verb.build
         and not args.force
         and Path(".mkosi-private/history/latest.json").exists()