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

@n44/git-switcher

v1.2.0

Published

Switch and manage multiple GitHub accounts using GitHub CLI.

Downloads

249

Readme

git-switcher

npm version npm downloads Node.js License: MIT

Switch and manage multiple GitHub accounts using GitHub CLI.

Features

  • Switch GitHub account with gh auth switch
  • Set up Git credential helper with gh auth setup-git
  • Save named account aliases for faster switching
  • Optionally set global git user.name and git user.email
  • Validate your local setup with a built-in doctor command

Requirements

  • Node.js 18+
  • GitHub CLI
  • Git
  • Logged in at least once with gh auth login

Installation

Global

npm install -g @n44/git-switcher

Global update

npm install -g @n44/git-switcher@latest

You can also run:

git-switcher update
git-switcher update --run

Local development

npm install
npm link

CLI names

After global install (or npm link), you can run it in any of the following ways:

git-switcher <command>
git switcher <command>
gs <command>
git s <command>

Commands

doctor

git-switcher doctor

Checks whether gh and git are available and verifies authentication status.

status

git-switcher status

Shows the current active account and gh auth status.

list

git-switcher list

Lists detected authenticated GitHub accounts.

switch

git-switcher switch <account>

Optional flags:

git-switcher switch <account> --setup-git
git-switcher switch <account> --git-name "Your Name" --git-email "[email protected]"

setup

git-switcher setup

Runs gh auth setup-git.

alias-add

git-switcher alias-add <alias> <account>

Optional profile fields:

git-switcher alias-add <alias> <account> --git-name "Your Name" --git-email "[email protected]"

aliases

git-switcher aliases

Lists all saved alias profiles.

use

git-switcher use <alias>

Optional flag:

git-switcher use <alias> --skip-setup

alias-rm

git-switcher alias-rm <alias>

Removes a saved alias profile.

update

git-switcher update

Shows the global npm update command. Use --run to execute it directly.

npmjs.com install command note

The install command shown in the npmjs sidebar is controlled by npm and usually defaults to npm i <package>. To show global install/update commands (-g) prominently, keep them in this README (npmjs renders this section).

Examples

# direct account switch
gs switch personal --setup-git

# create reusable profile
gs alias-add work john-work --git-name "John" --git-email "[email protected]"

# switch using saved profile
gs use work

Config storage

Alias profiles are stored in:

~/.git-switcher/config.json

This package does not store tokens or secrets.