]> git.ipfire.org Git - thirdparty/mkosi.git/commit
Implement CacheOnly=metadata 2336/head
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Wed, 31 Jan 2024 13:13:37 +0000 (14:13 +0100)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Wed, 31 Jan 2024 13:45:47 +0000 (14:45 +0100)
commit2694f533346a5fef91048b24a969d5b97820d717
treeb5411a9346329a11eda036d17cea4b5793e7f872
parent7b9290492d43552d1f249fb67c57b2a58f0fb385
Implement CacheOnly=metadata

We make CacheOnly= take an enum but keep backwards compat with the
boolean argument as well.

CacheOnly=metadata means we'll download packages but we won't sync
repository metadata. We also enable this in the kernel-install so that
our built initrds use exactly the same package versions as the host
system.

While we're at it we rename the internal variable to cacheonly instead
of cache_only (to match dnf's --cacheonly option). We keep the user
facing stuff the same to not break backwards compat.

We also make all of our enum functions take StrEnum as argument instead
of the generic enum.Enum.
NEWS.md
kernel-install/50-mkosi.install
mkosi/__init__.py
mkosi/config.py
mkosi/installer/dnf.py
mkosi/resources/mkosi.md
tests/test_json.py