# Install git-delete-merged-branches with Homebrew, apt, Nix

Command-line tool to delete merged Git branches. Version 7.6.0 via Homebrew; verified 2026-06-18.

## Install

```sh
sudo av install brew:git-delete-merged-branches
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install git-delete-merged-branches
```

  Evidence: local Homebrew formula metadata

### Linux

- Debian apt (92%):

```sh
sudo apt install git-delete-merged-branches
```

  Evidence: Debian stable package indexes: git-delete-merged-branches from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- Nix (92%):

```sh
nix profile install nixpkgs#git-delete-merged-branches
```

  Evidence: nixpkgs package indexes: pkgs/by-name/gi/git-delete-merged-branches/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

## Package facts

- **Package key:** brew:git-delete-merged-branches
- **Package manager:** Homebrew
- **Package manager page:** <https://formulae.brew.sh/formula/git-delete-merged-branches>
- **Version:** 7.6.0
- **Source summary:** Command-line tool to delete merged Git branches
- **Homepage:** <https://github.com/hartwork/git-delete-merged-branches>
- **Repository:** <https://github.com/hartwork/git-delete-merged-branches>
- **Upstream docs:** <https://github.com/hartwork/git-delete-merged-branches#readme>
- **License:** GPL-3.0-or-later
- **Source archive:** <https://files.pythonhosted.org/packages/f5/1c/408c4061353020636b16620487ebd36e5ec5b4ebec89ba2af4817698f5c1/git_delete_merged_branches-7.6.0.tar.gz>
- **Last updated:** 2026-06-18T09:25:51+09:00
- **Generated:** 2026-07-08T07:18:31+00:00

## Executables

- git-dmb (cli)
- git-dmb (alias)

## Dependencies

- python@3.14

## Install behavior

- Post-install hook: not defined
- Bottle: available on all

## Freshness

- Page generated: 2026-07-08
- Package-manager version: 7.6.0
- Package-manager updated: 2026-06-18
- Local data: ok
- Upstream repository: https://github.com/hartwork/git-delete-merged-branches
- info: No cached GitHub release or tag data was available.
## Project history and usage

git-delete-merged-branches is a Python command-line tool for cleaning up local and remote Git branches after their work has been merged. Its package installs the shorter `git-dmb` executable and documents safety-focused branch deletion.

### Project history

The upstream Git history begins in July 2020 with code for version 1.0.0. The project advanced quickly through early releases and later settled into a maintained CLI with tests, pre-commit integration, and package-manager distribution.

The README frames the tool around safe cleanup rather than raw deletion. It detects multiple forms of de-facto merges, including rebase merges, squash merges with extra effort, and cherry-picks by leveraging `git cherry`; it also supports workflows with multiple release branches.

### Adoption history

The official README lists install paths through pip and distribution packages including Arch AUR, Debian, Gentoo, Homebrew, MacPorts, NixOS, Ubuntu, and Void Linux. That makes the tool visible in the same package-manager space as Git workflow helpers rather than only as a Python package.

Its README also documents a command-name clash with git-extras, whose utility collection ships a simpler `git-delete-merged-branches` script. The standalone project responds by offering `python3 -m git_delete_merged_branches` and `git-dmb` invocation paths.

### How it is used

Practitioners run it inside a repository to update remotes, fast-forward tracked release branches, list local and remote branches that appear merged, and ask before deletion. A `--dry-run` mode lets users inspect actions first, and `--verbose` shows Git commands.

The tool is used when teams accumulate topic branches across local clones, forks, and remote hosts. It is provider-agnostic and documents use with GitHub, GitLab, Gitea, and other Git hosting because it works through Git commands rather than a hosting API.

### Why package nerds care

The package is a good example of a small workflow CLI whose value lies in guardrails: branch deletion is risky, so the project packages conservative prompts, dry runs, `--force-with-lease`, and no shell-command construction.

Its overlap with git-extras is package-manager-relevant because PATH order can decide which command a user runs when both packages are installed.

### Timeline

- 2020: The repository begins with version 1.0.0 code.
- 2020: Rapid 1.x through 6.x releases establish the CLI and packaging shape.
- 2021: Version 6.4.0 continues the maintained Python CLI line.
- 2022: Version 7.4.0 lands after several 7.x releases.
- 2025: Version 7.5.0 is released.
- 2026: Version 7.6.0 is released.

### Related projects

- git-extras is a related utility collection and a direct command-name conflict noted by the README.
- GitHub's automatic deletion of branches for merged pull requests is mentioned as a complementary hosting-side cleanup feature.
- `git cherry` is the Git command named by the README as part of merge-detection logic.

### Sources

- <https://formulae.brew.sh/formula/git-delete-merged-branches documents Homebrew packaging.>
- <https://github.com/hartwork/git-delete-merged-branches documents installation, examples, features, safety rules, best practices, and the git-extras command-name clash.>
- <https://github.com/hartwork/git-delete-merged-branches/releases documents release progression.>


## Security Notes

narrow executable package without higher-risk signals.

- **Geiger risk:** green / low
- narrow executable package without higher-risk signals

## Source Database Details

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** git-delete-merged-branches
- **Version Scheme:** 0
- **Revision:** 0
- **Conflicts With:** git-extras
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

## Other Package-Manager Records

- Debian apt - git-delete-merged-branches - 7.5.0-1: normalized package name match | Debian stable package indexes: git-delete-merged-branches from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | command-line tool to delete merged git branches | https://github.com/hartwork/git-delete-merged-branches
- Debian apt - python3-git-delete-merged-branches - 7.5.0-1: normalized package name match | Debian stable package indexes: python3-git-delete-merged-branches from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | command-line tool to delete merged git branches (Python module) | https://github.com/hartwork/git-delete-merged-branches
- Nix - git-delete-merged-branches: normalized package name match | nixpkgs package indexes: pkgs/by-name/gi/git-delete-merged-branches/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - git-delete-merged-branches - 7.4.0-1: normalized package name match | Ubuntu 24.04 LTS package indexes: git-delete-merged-branches from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | command-line tool to delete merged git branches | https://github.com/hartwork/git-delete-merged-branches
- Ubuntu apt - python3-git-delete-merged-branches - 7.4.0-1: normalized package name match | Ubuntu 24.04 LTS package indexes: python3-git-delete-merged-branches from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | command-line tool to delete merged git branches (Python module) | https://github.com/hartwork/git-delete-merged-branches


## Related links

- [Source-control packages](https://www.automicvault.com/pkg/source-control-tools/) - Belongs to a source-control command family.
- [Terminal utility packages](https://www.automicvault.com/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Text processing packages](https://www.automicvault.com/pkg/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [Developer build packages](https://www.automicvault.com/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [python@3.14](https://www.automicvault.com/pkg/brew/python-3-14/) - Runtime dependency declared by Homebrew.
- [git-delta](https://www.automicvault.com/pkg/brew/git-delta/) - Shares av.db curated category or tags: cli, developer-tools, git, git-extensions, version-control.
- [git-extras](https://www.automicvault.com/pkg/brew/git-extras/) - Shares av.db curated category or tags: cli, developer-tools, git, git-extensions, version-control.
- [git-filter-repo](https://www.automicvault.com/pkg/brew/git-filter-repo/) - Shares av.db curated category or tags: cli, developer-tools, git, git-extensions, version-control.
- [git-flow](https://www.automicvault.com/pkg/brew/git-flow/) - Shares av.db curated category or tags: cli, developer-tools, git, git-extensions, version-control.
- [git-format-staged](https://www.automicvault.com/pkg/brew/git-format-staged/) - Shares av.db curated category or tags: cli, developer-tools, git, git-extensions, version-control.
- [git-fresh](https://www.automicvault.com/pkg/brew/git-fresh/) - Shares av.db curated category or tags: cli, developer-tools, git, git-extensions, version-control.
- [git-lfs](https://www.automicvault.com/pkg/brew/git-lfs/) - Shares av.db curated category or tags: cli, developer-tools, git, git-extensions, version-control.
- [git-integration](https://www.automicvault.com/pkg/brew/git-integration/) - Shares av.db curated category or tags: branch-management, cli, developer-tools, git, version-control.
- [git-machete](https://www.automicvault.com/pkg/brew/git-machete/) - Both packages touch the same language runtime or ecosystem. Shared terms: branch, branch-management, cli, control, developer.
- [git-plus](https://www.automicvault.com/pkg/brew/git-plus/) - Both packages touch the same language runtime or ecosystem. Shared terms: branch, branch-management, branches, cli, control.

## Combined YAML source

View the package source record on GitHub. [combined/git-delete-merged-branches.yml](https://github.com/automic-vault/db/blob/main/combined/git-delete-merged-branches.yml)


## Sources

- Nucleus package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- av.db category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
