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-barber

v0.1.0

Published

πŸ’ˆ A neat CLI tool for managing structured, nested Git branches.

Readme

πŸ’ˆ Git Barber CLI

A neat CLI tool for managing structured, nested Git branches.


Installation

Install globally via npm:

npm install -g git-barber

Usage

Declare a Base Branch

Declares a base branch, e.g. feature/paymentsBaseBranch. You may optionally specify the branch name, otherwise the CLI will prompt you to type one. If the specified branch does not exist, it will be created, so you can use this both with existing branches and new ones.

git-barber declare-base <branch>

Example:

git-barber declare-base feature/paymentsBaseBranch

Status - List all branches

Shows a tree-list of all declared branches, including the estimated PR size for each one.

git-barber status

Example output:

Current Branch Tree:
feature/analyticsDashboardOverview/baseBranch
  feature/analyticsDashboardOverview/topRoomDetailsBox (+162 -155)
    feature/analyticsDashboardOverview/mostVisitedTabs (+419 -44)
      feature/analyticsDashboardOverview/crmInsights (+290 -78)
        feature/analyticsDashboardOverview/crmInsights-2 (+262 -73)	πŸ‘ˆ you're here
          feature/analyticsDashboardOverview/tooltips (+61 -10)

Checkout one of the branches

Though you can just use normal git checkout, this command will show you an interactive tree-list of your branches for a better experience.

git-barber checkout

Create Nested Branches

Interactively creates nested branches based on an existing branch hierarchy. When run without arguments, the CLI will prompt you to select a parent branch and enter a new branch name interactively. Alternatively, you can provide an optional branch name as a positional argument:

git-barber branch [branchName]
  • If the given branch name already exists locally, it will be registered as a child of the selected parent branch.
  • If it does not exist, the CLI will automatically create the new branch using the chosen parent as its base.

For example:

Interactively create a new nested branch (you will be prompted for the input)

git-barber branch

Create / register existing branch as a child:

git-barber branch feature/paymentsPaypal

After invoking the command, you'll see a visual tree-like structure for choosing the parent branch:

baseBranch
  β”œβ”€β”€ childBranch
  └── anotherChild
      └── grandChild

Sync Branches

Synchronizes changes by merging from a selected ancestor branch down through its descendants:

git-barber sync

Example output:

βœ” Select branch to start sync from: 
dev (ancestor of feature/analyticsDashboardOverview/baseBranch)

βœ… Merged dev into feature/analyticsDashboardOverview/baseBranch

βœ… Merged feature/analyticsDashboardOverview/baseBranch into feature/analyticsDashboardOverview/topRoomDetailsBox

βœ… Merged feature/analyticsDashboardOverview/topRoomDetailsBox into feature/analyticsDashboardOverview/mostVisitedTabs

βœ… Merged feature/analyticsDashboardOverview/mostVisitedTabs into feature/analyticsDashboardOverview/crmInsights

βœ… Merged feature/analyticsDashboardOverview/crmInsights into feature/analyticsDashboardOverview/crmInsights-2

βœ… Merged feature/analyticsDashboardOverview/crmInsights-2 into feature/analyticsDashboardOverview/tooltips

Sync complete!

Choose your starting branch interactively from an indented tree.

This addresses one of the biggest pain points of "base branches" - merging an ancestor to its descendants.

Delete Branches

Remove selected branch(es) locally. This command presents a multi-select prompt where you can choose the branch(es) to delete. Only the branch(es) you select will be removed, and the configuration will be updated accordingly.

Usage:

git-barber delete

Use this to clear up the clutter of branches that you've already merged.

Config

Shows an interactive configuration menu for the:

  • large diff threshold: how many added lines for a single branch warrant a warning?
  • ignore patterns: patterns of files to exclude from the diff calculation, e.g. images, videos, etc.
git-barber config

Reset Bases

Deletes the configuration file that contains data about your branches. Use this when you need to start fresh.

git-barber reset-bases