v1.0.0 Release

Stop copy-pasting keys & emails.

The interactive developer CLI that switches your Git profiles, GPG signing keys, SSH credentials, and HTTPS tokens instantly.

bash — git-profile list
$ git-profile list

Git Profiles:

* personal [Default Global]
  Name:   Pavel Personal
  Email:  pavelkortp@gmail.com
  SSH:    ~/.ssh/id_ed25519_personal
  GPG:    PERSONALGPG123
  Service User: pavelkortp (github.com)

* work [Local Active]
  Name:   Pavel Work
  Email:  pavel.zhurbytskyi@work.com
  SSH:    ~/.ssh/id_rsa_work
  GPG:    WORKGPG456
  Service User: pavel-work (github.com)

Features

👤

Multi-Identity

Define independent git credentials for work, personal projects, or client tasks in one configuration.

🛡️

Dynamic SSH Keys

Uses Git's core.sshCommand inside the repo config. No more manual updates to ~/.ssh/config.

🔑

Keychain Isolation

Configures distinct credential helper usernames so macOS separates tokens for different accounts.

Zero Dependencies

Built with pure Node.js APIs. Light, blazing fast, and instantly executable with zero npm baggage.

Installation

Select your preferred installation method to install the CLI globally on your machine.

Via Homebrew (macOS)

Tap the repository and install the formula:

brew tap pavelkortp/tap
brew install git-profile

Via NPM

Install the package globally from the registry:

npm install -g @p-pavlo/git-profile

Usage Guide

The CLI is designed to be interactive, intuitive, and clean.

Interactive Commands

git-profile add [name]
Interactively guides you through profile creation (Name, Email, SSH file path, GPG Key ID, and Token).
git-profile list
Lists all configurations and highlights currently active local and global profiles.
git-profile use <name>
Applies the profile. Defaults to --local if inside a git repo, or --global if outside.
git-profile use <name> --global
Forces global scope application (updates your global ~/.gitconfig).
git-profile env <name>
Generates shell export lines. Run eval $(git-profile env work) to inject variables like GITHUB_TOKEN.

Interactive Profile Creator

Fill out the form below to generate a valid configuration file. You can manually paste this into your ~/.git-profiles.json file.

~/.git-profiles.json