From: Jonathan Lebon Date: Fri, 8 Sep 2023 19:05:37 +0000 (-0400) Subject: app/pull-local: Add `--disable-static-delta` X-Git-Tag: archive/raspbian/2023.7-3+rpi1^2~16^2^2~23^2~4 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=3c2587b619a268bd83ab4924a905e0b325250b73;p=ostree.git app/pull-local: Add `--disable-static-delta` For completeness with `pull`. Prep for using it in testing to assert we'll never use static deltas. --- diff --git a/src/ostree/ot-builtin-pull-local.c b/src/ostree/ot-builtin-pull-local.c index 6ea8da05..d489c44b 100644 --- a/src/ostree/ot-builtin-pull-local.c +++ b/src/ostree/ot-builtin-pull-local.c @@ -36,6 +36,7 @@ static gboolean opt_per_object_fsync; static gboolean opt_untrusted; static gboolean opt_bareuseronly_files; static gboolean opt_require_static_deltas; +static gboolean opt_disable_static_deltas; static gboolean opt_gpg_verify; static gboolean opt_gpg_verify_summary; static gboolean opt_disable_verify_bindings; @@ -60,6 +61,8 @@ static GOptionEntry options[] "Reject regular files with mode outside of 0775 (world writable, suid, etc.)", NULL }, { "require-static-deltas", 0, 0, G_OPTION_ARG_NONE, &opt_require_static_deltas, "Require static deltas", NULL }, + { "disable-static-deltas", 0, 0, G_OPTION_ARG_NONE, &opt_disable_static_deltas, + "Do not use static deltas", NULL }, { "gpg-verify", 0, 0, G_OPTION_ARG_NONE, &opt_gpg_verify, "GPG verify commits (must specify --remote)", NULL }, { "gpg-verify-summary", 0, 0, G_OPTION_ARG_NONE, &opt_gpg_verify_summary, @@ -186,6 +189,9 @@ ostree_builtin_pull_local (int argc, char **argv, OstreeCommandInvocation *invoc if (opt_remote) g_variant_builder_add (&builder, "{s@v}", "override-remote-name", g_variant_new_variant (g_variant_new_string (opt_remote))); + g_variant_builder_add ( + &builder, "{s@v}", "disable-static-deltas", + g_variant_new_variant (g_variant_new_boolean (opt_disable_static_deltas))); g_variant_builder_add ( &builder, "{s@v}", "require-static-deltas", g_variant_new_variant (g_variant_new_boolean (opt_require_static_deltas)));