From: reuben olinsky Date: Fri, 28 Oct 2022 02:51:41 +0000 (-0700) Subject: Allow uncompressed squashfs images X-Git-Tag: v15~397 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=255741d0e8337a06517641eae2c4fc4166791897;p=thirdparty%2Fmkosi.git Allow uncompressed squashfs images The argument parsing was blocking this but the logic invoking mksquashfs already supported it. --- diff --git a/mkosi/__init__.py b/mkosi/__init__.py index 28a3f11ab..218099b8e 100644 --- a/mkosi/__init__.py +++ b/mkosi/__init__.py @@ -6583,8 +6583,6 @@ def load_args(args: argparse.Namespace) -> MkosiConfig: if args.root_size is None: # Size will be automatic args.minimize = True - if args.compress is False: - die("Cannot disable compression with squashfs", MkosiNotSupportedException) if args.compress is None: args.compress = True diff --git a/tests/test_parse_load_args.py b/tests/test_parse_load_args.py index 7ded908c2..9646ed826 100644 --- a/tests/test_parse_load_args.py +++ b/tests/test_parse_load_args.py @@ -135,6 +135,5 @@ def test_shell_boot() -> None: def test_compression() -> None: assert parse(["--format", "gpt_squashfs"]).compress - with pytest.raises(MkosiException, match=".*compression.*squashfs"): - parse(["--format", "gpt_squashfs", "--compress", "False"]) + assert not parse(["--format", "gpt_squashfs", "--compress", "False"]).compress