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 🙏

© 2025 – Pkg Stats / Ryan Hefner

gitpersonax

v1.0.3

Published

GitPersonaX - Git profile management tool - quickly switch between multiple Git accounts

Readme

GitPersonaX

A command-line tool similar to GitKraken Profile that helps you quickly switch between multiple Git accounts, including username, email, SSH Key and other configurations.

Features

  • ✅ Multiple Git profile management
  • ✅ Quick profile switching
  • ✅ Automatic git config (user.name, user.email)
  • ✅ Automatic SSH config
  • ✅ GPG signing key support
  • ✅ Interactive UI

Installation

npm install -g gitpersonax

Usage

Add a new profile

gitpersonax add

Follow the prompts to enter:

  • Profile name (e.g., company, personal)
  • Git Username
  • Git Email
  • SSH Key path (e.g., ~/.ssh/id_rsa_company)
  • GPG Signing Key (optional)

List all profiles

gitpersonax list
# or
gitpersonax ls

Switch to a specified profile

# Interactive selection
gitpersonax switch

# Specify directly
gitpersonax switch company
gitpersonax use company

Delete a profile

# Interactive selection
gitpersonax delete

# Specify directly
gitpersonax delete company
gitpersonax rm company

View current profile

gitpersonax current

Initialize config directory

gitpersonax init

Usage Examples

Scenario 1: Add company and personal accounts

# Add company account
$ gitpersonax add
Profile name: company
Git Username: John Doe
Git Email: [email protected]
SSH Key path: ~/.ssh/id_rsa_company
GPG Signing Key: (leave empty or enter)
Switch to this profile automatically? No

# Add personal account
$ gitpersonax add
Profile name: personal
Git Username: Jane Doe
Git Email: [email protected]
SSH Key path: ~/.ssh/id_rsa_personal
GPG Signing Key: ABCD1234EFGH5678
Switch to this profile automatically? Yes

Scenario 2: Quickly switch accounts

# View current account
$ gitpersonax current
👤 Current Git Profile:
  Name: personal
  User: Jane Doe
  Email: [email protected]
  SSH Key: ~/.ssh/id_rsa_personal
  GPG Key: ABCD1234EFGH5678

# Switch to company account
$ gitpersonax switch company
🔧 Updating Git config...
🔐 Updating SSH config...

✅ Switched to profile: company
   Username: John Doe
   Email:    [email protected]
   SSH Key:  ~/.ssh/id_rsa_company

Configuration File

The tool creates configuration files in ~/.git-profile/ directory:

  • profiles.json - Store all profile information

Example content:

{
  "profiles": {
    "company": {
      "username": "John Doe",
      "email": "[email protected]",
      "sshKey": "~/.ssh/id_rsa_company",
      "signingKey": null,
      "createdAt": "2025-11-25T15:30:00.000Z"
    },
    "personal": {
      "username": "Jane Doe",
      "email": "[email protected]",
      "sshKey": "~/.ssh/id_rsa_personal",
      "signingKey": "ABCD1234EFGH5678",
      "createdAt": "2025-11-25T15:30:00.000Z"
    }
  },
  "current": "personal"
}

SSH Configuration

When switching profiles, the tool automatically updates ~/.ssh/config file and adds Host configuration for each profile:

# GitPersonaX: company
Host company
  HostName github.com
  User git
  IdentityFile ~/.ssh/id_rsa_company
  IdentitiesOnly yes

# GitPersonaX: personal
Host personal
  HostName github.com
  User git
  IdentityFile ~/.ssh/id_rsa_personal
  IdentitiesOnly yes

Usage with different hosts:

# Clone personal repository
git clone git@personal:username/repo.git

# Clone company repository
git clone git@company:username/repo.git

Quick Command Reference

| Command | Description | |---------|-------------| | gitpersonax add | Add new profile | | gitpersonax list | View all profiles | | gitpersonax switch | Switch profile | | gitpersonax delete | Delete profile | | gitpersonax current | View current profile |

Notes

  1. Ensure SSH Key file exists and path is correct
  2. Switching profile will modify global git configuration
  3. Cannot delete current active profile, must switch to another profile first
  4. Using GPG signing requires pre-configured GPG keys

License

This project is licensed under the MIT License - see the LICENSE file for details.