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

v0.1.17

Published

A tool for managing stacked Git branches with powerful commands for navigation, rebasing, and atomic operations.

Readme

git-stack2

A tool for managing stacked Git branches with powerful commands for navigation, rebasing, and atomic operations.

Installation

npm install -g git-stack2

Usage

Show current stack

git stack

This displays all branches in your current stack, with the current branch highlighted.

Navigate the stack

Move up one branch (toward the tip):

git stack up

Move down one branch (toward the base):

git stack down

Jump to the top of the stack:

git stack top

Jump to the bottom of the stack:

git stack bottom

Modify commits in a stack

Amend the current commit and automatically rebase dependent branches:

git amend
# Pass any git commit --amend flags
git amend --no-edit
git amend -m "Updated commit message"

Insert a new commit/branch and automatically rebase dependent branches:

git insert
# Pass any git commit flags
git insert -m "New feature"

Sync with remote

Pull all topmost branches in the current stack with rebase:

git stack pull

Push all branches in the current stack atomically:

git stack push

Move the entire stack

Move your entire stack onto a different base branch:

git stack move <branch>
# Example: move stack from main to develop
git stack move develop

How it works

The tool identifies your git stack by:

  1. Finding all local branches in the repository
  2. Determining the default branch (main or master)
  3. Computing the merge-base of each branch with the default branch to narrow the scope of "relevant changes"
  4. Building a graph of parent-child relationships using git log

This allows you to easily navigate through a stack of related feature branches. It's also easy to migrate from any existing git stack tool, since it doesn't store any state.

Example

If you have branches structured like:

  • main (base)
  • feature-1 (based on main)
  • feature-2 (based on feature-1)
  • feature-3 (based on feature-2)

When you're on feature-2, running git stack will show:

Current stack:
────────────────────────────────────────
  feature-3
  │
→ feature-2 (current)
  │
  feature-1
────────────────────────────────────────

Total branches in stack: 3

You can then use git stack up to move to feature-3 or git stack down to move to feature-1.