Files
git/Documentation
Harald Nordgren b201bdb32d branch: add --forked filter for --list mode
Add a --forked option to "git branch" list mode that keeps only
branches whose configured upstream matches <branch>. The argument
can be a ref (e.g. "origin/main", "master") or a shell-style
glob (e.g. "origin/*"). The option can be repeated to widen the
filter.

Because it is a filter on list mode, --forked composes with the
existing list-mode filters, so

    git branch --merged origin/main --forked 'origin/*'

lists branches forked from origin that have already been
integrated into origin/main, and --no-merged inverts the question.

This is the building block for --prune-merged, which deletes the
listed branches once they have landed on their upstream.

Signed-off-by: Harald Nordgren <haraldnordgren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2026-06-03 19:10:04 +09:00
..
2025-03-01 10:26:15 -08:00
2026-04-13 13:54:57 -07:00
2025-12-14 17:04:37 +09:00
2026-03-06 13:02:20 -08: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