]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Decouple base trees from repository metadata snapshot 2339/head
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Thu, 1 Feb 2024 11:32:43 +0000 (12:32 +0100)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Thu, 1 Feb 2024 11:32:43 +0000 (12:32 +0100)
The syncing can be disabled with CacheOnly=metadata and we already
don't use repository metadata that's already populated so let's not
imply anything specific when using base trees so that base trees
without repository metadata can still be used to build extension
images.

mkosi/__init__.py

index 2b92536210f6e68a827ac121a07e2fa63ddbb7da..7cbc22d9ce45be27d5c91f915599cb49b53807aa 100644 (file)
@@ -2946,7 +2946,7 @@ def setup_workspace(args: Args, config: Config) -> Iterator[Path]:
 
 
 def copy_repository_metadata(context: Context) -> None:
-    if have_cache(context.config) or context.config.base_trees:
+    if have_cache(context.config):
         return
 
     subdir = context.config.distribution.package_manager(context.config).subdir(context.config)
@@ -3601,7 +3601,7 @@ def rchown_package_manager_dirs(config: Config) -> Iterator[None]:
 
 
 def sync_repository_metadata(args: Args, config: Config, *, resources: Path) -> None:
-    if have_cache(config) or config.cacheonly != Cacheonly.none or config.base_trees:
+    if have_cache(config) or config.cacheonly != Cacheonly.none:
         return
 
     with (