Files
git/Documentation
Alan Braithwaite acefb71d0d clone: add clone.<url>.defaultObjectFilter config
Add a new configuration option that lets users specify a default
partial clone filter, optionally scoped by URL pattern.  When
cloning a repository whose URL matches a configured pattern,
git-clone automatically applies the filter, equivalent to passing
--filter on the command line.

    [clone]
        defaultObjectFilter = blob:limit=1m

    [clone "https://github.com/"]
        defaultObjectFilter = blob:limit=5m

    [clone "https://internal.corp.com/large-project/"]
        defaultObjectFilter = blob:none

The bare clone.defaultObjectFilter applies to all clones.  The
URL-qualified form clone.<url>.defaultObjectFilter restricts the
setting to matching URLs.  URL matching uses the existing
urlmatch_config_entry() infrastructure, following the same rules as
http.<url>.* — a domain, namespace, or specific project can be
matched, and the most specific match wins.

The config only affects the initial clone.  Once the clone completes,
the filter is recorded in remote.<name>.partialCloneFilter, so
subsequent fetches inherit it automatically.  An explicit --filter
on the command line takes precedence, and --no-filter defeats the
configured default entirely.

Signed-off-by: Alan Braithwaite <alan@braithwaite.dev>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2026-03-15 14:24:19 -07:00
..
2026-03-05 10:04:49 -08:00
2025-03-01 10:26:15 -08:00
2026-03-02 17:06:52 -08:00
2025-12-14 17:04:37 +09:00
2025-10-02 12:26:12 -07:00
2025-02-14 17:53:47 -08:00
2025-12-05 14:49:56 +09:00
2025-12-16 09:42:44 +09:00