npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

git-merged-branches

v0.4.0

Published

CLI tool to list all Git branches merged into a base branch with issue link formatting

Readme

git-merged-branches

npm version npm downloads build ask DeepWiki

git-merged-branches is a command-line utility to view branches merged into a selected base branch (e.g., master or main).

  • CLI usage
  • customizable via package.json

Installation

Install globally to use git-merged-branches or the shorter version gmb:

npm install --global git-merged-branches

Or use it without installation via npx:

npx git-merged-branches

Usage

By default, the command shows merged branches into the base branch (master or main). If neither exists, it will notify you.

Example output:

$ git-merged-branches
2 branches merged into master:
fix/crash-on-start
feat/add-new-feature

You can also delete these merged branches with the --delete option:

$ git-merged-branches --delete
2 branches merged into master:
fix/crash-on-start
feature/add-new-feature

Deleting branches locally…
Deleting branches remotely…
Branches deleted successfully.

Configuration

You can configure the utility in your package.json under git-merged-branches. This allows you to set:

  • issueUrlFormat: Base URL for your issue tracker (must be a valid URL).
    • For JIRA-style trackers, you can can include the prefix in the URL: https://your-jira-instance.net/browse/{{prefix}}{{id}}.
    • Fir GitHub-style issues, omit the prefix in the URL: https://github.com/org/repo/issues/{{id}}.
  • issueUrlPrefix: Array of prefixes for issue identifiers in branch names.

Example configuration for JIRA:

"git-merged-branches": {
  "issueUrlFormat": "https://your-jira-instance.net/browse/{{prefix}}{{id}}",
  "issueUrlPrefix": ["TOKEN-", "PROJECT-"]
}

Example configuration for GitHub:

"git-merged-branches": {
  "issueUrlFormat": "https://github.com/org/repo/issues/{{id}}",
  "issueUrlPrefix": ["#"]
}

With this setup, git-merged-branches will generate links for branches with such tokens in their name:

$ git-merged-branches
4 branches merged into master:
fix/EXTERNAL-391
fix/TOKEN-123_some-fix https://your-jira-instance.net/browse/TOKEN-123
hotfix
TOKEN-800_new-feature https://your-jira-instance.net/browse/TOKEN-800
refactor/#55_cleanup https://github.com/org/repo/issues/55

If the configuration is invalid, warnings will be shown and the utility will skip formatting URLs.

Documentation

Development

To contribute or test locally:

  1. Clone the repository:

    git clone https://github.com/VChet/git-merged-branches.git
    cd git-merged-branches
  2. Install dependencies:

    pnpm install
  3. Build the project:

    pnpm run build
  4. Link it locally for testing:

    npm link

Now you can run git-merged-branches on your local machine.

Contributing

If you have any ideas, bug reports, or feature requests, feel free to contribute or report issues.