Files
git/Documentation
Harald Nordgren 876029beca branch: add --forked filter for --list mode
Add a --forked option to "git branch" list mode that lists only
branches whose configured upstream matches <branch>. The argument
can be a ref (e.g. "origin/main", "master"), a remote name like
"origin" for the branch its origin/HEAD points at, or a shell glob
(e.g. "origin/*"), and may be repeated to widen the filter.

It is an ordinary list filter, so it combines with the others:

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

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

This is the building block for --delete-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-08-05 10:08:27 -07:00
..
2026-07-27 09:09:01 -07:00
2026-06-15 07:42:00 -07:00
2026-06-05 22:27:24 +09:00
2025-12-14 17:04:37 +09:00
2026-03-06 13:02:20 -08:00
2025-12-05 14:49:56 +09:00
2026-05-21 12:06:48 +09:00
2025-12-16 09:42:44 +09:00