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

@suhailroushan/gitai

v1.0.6

Published

AI-powered Git CLI — commit, push, branch, and more with DeepSeek AI

Readme

gitai

AI-Powered Git CLI

Commit, push, branch, stash, undo and more — with AI-generated commit messages, PR descriptions, security scans, and a built-in Git reference.

npm version license GitHub stars

InstallationUninstallSetupUsageFeaturesDocsContributingLicense


📦 Installation

Prerequisites

Make sure you have these installed:

| Tool | Check | Install | |------|-------|---------| | Git | git --version | git-scm.com | | Node.js (>=16) | node -v | nodejs.org | | jq | jq --version | brew install jq / sudo apt install jq | | curl | curl --version | Pre-installed on most systems |

Install with npm

npm install -g @suhailroushan/gitai

Install with pnpm

pnpm add -g @suhailroushan/gitai

Install with yarn

yarn global add @suhailroushan/gitai

Install from source

git clone https://github.com/suhailroushan13/gitai.git
cd gitai
npm install -g .

Uninstall

To remove GitAI from your system, use the same package manager you used to install:

# npm (default with nvm; binary often in ~/.nvm/versions/node/*/bin/)
npm uninstall -g @suhailroushan/gitai

# pnpm
pnpm remove -g @suhailroushan/gitai

# yarn
yarn global remove @suhailroushan/gitai

If you're not sure which one is active, run which gitai — if the path contains nvm, use npm; if it contains pnpm, use pnpm. If you installed with more than one manager, run the matching uninstall for each.

If you installed from source with npm install -g ., run npm uninstall -g @suhailroushan/gitai from any directory.

Verify installation

gitai --help

You should see:

  gitai — AI-powered Git CLI
  Usage: gitai [option]

  Options:
    --docs, -d, docs   Show full Git reference (setup, SSH, commands)
    --help, -h         Show this help

  With no options, starts the interactive menu.

🔧 Setup

1. Get a DeepSeek API Key

GitAI uses DeepSeek AI to generate commit messages, PR descriptions, and more.

  1. Go to platform.deepseek.com
  2. Sign up or log in
  3. Navigate to API Keys and create a new key
  4. Copy the key (starts with sk-)

2. Add the API Key to your shell

For zsh (default on macOS):

echo 'export DEEPSEEK_API_KEY="sk-your-key-here"' >> ~/.zshrc
source ~/.zshrc

For bash:

echo 'export DEEPSEEK_API_KEY="sk-your-key-here"' >> ~/.bashrc
source ~/.bashrc

Verify it's set:

echo $DEEPSEEK_API_KEY

3. Configure Git (if not already done)

git config --global user.name "Your Name"
git config --global user.email "[email protected]"
git config --global init.defaultBranch main

4. Set up SSH Keys (recommended)

SSH keys let you push/pull without entering your password every time.

Generate a new Ed25519 key:

ssh-keygen -t ed25519 -C "[email protected]"
  • Press Enter to accept the default path (~/.ssh/id_ed25519)
  • Optionally set a passphrase

Start the SSH agent and add your key:

eval "$(ssh-agent -s)"
ssh-add ~/.ssh/id_ed25519

Copy the public key:

# macOS
pbcopy < ~/.ssh/id_ed25519.pub

# Linux
cat ~/.ssh/id_ed25519.pub

Add to GitHub:

  1. Go to GitHubSettingsSSH and GPG keys
  2. Click New SSH key
  3. Paste your key, give it a title, and click Add SSH key

Test the connection:

ssh -T [email protected]

You should see: "Hi username! You've successfully authenticated..."


🚀 Usage

Start the interactive menu

gitai

Quick commands

| Command | Description | |---------|-------------| | gitai | Launch interactive menu | | gitai --docs | Show full Git reference & notes | | gitai docs | Same as above | | gitai -d | Same as above | | gitai --help | Show help | | gitai -h | Same as above |

First commit workflow

# Create a project
mkdir my-project && cd my-project
git init

# Write some code...

# Launch gitai
gitai

# Choose option 1 → AI Commit & Push
# GitAI will:
#   1. Stage all changes (git add .)
#   2. Generate an AI commit message from your diff
#   3. Commit with the message
#   4. Push to origin

✨ Features

29 commands organized into 7 categories:

🚀 Commit & Push

| # | Command | Description | |---|---------|-------------| | 1 | AI Commit & Push | Auto-generate a semantic commit message using AI and push | | 2 | Manual Commit & Push | Write your own message, commit, and push | | 3 | Stage All & Status | git add . + git status | | 4 | Force Push | Overwrite remote (with confirmation) |

🔄 Sync & Branches

| # | Command | Description | |---|---------|-------------| | 5 | Pull & Rebase | Fetch + replay your commits on top | | 6 | Pull & Merge | Fetch + merge commit | | 7 | List Branches | All local + remote branches | | 8 | Create & Switch Branch | git checkout -b <name> | | 9 | Switch Branch | git checkout <name> | | 10 | Delete Branch | Local and/or remote (prevents deleting current branch) |

📜 History & Diff

| # | Command | Description | |---|---------|-------------| | 11 | Git Log | Pretty graph of recent 25 commits | | 12 | Show Diff | Staged, unstaged, or vs last commit | | 13 | Git Status | Full working tree status | | 14 | List Tags | All tags (newest first) | | 15 | Search Commits | Grep through commit messages |

📦 Stash & Undo

| # | Command | Description | |---|---------|-------------| | 16 | Stash Changes | Save work temporarily | | 17 | Pop Stash | Restore stashed changes | | 18 | List Stashes | See all stash entries | | 19 | Undo Last Commit | Soft reset (keeps changes staged) | | 20 | Discard All Changes | Hard reset to last commit (with confirmation) |

🤖 AI Tools

| # | Command | Description | |---|---------|-------------| | 21 | AI Explain Last Commit | Plain-English summary of what changed | | 22 | AI Suggest Branch Name | Generate a branch name from your diff | | 23 | AI Generate PR Description | Full PR write-up from recent commits | | 24 | AI Security Scan Diff | Spot hardcoded secrets, API keys, and vulnerabilities |

⚙️ Config

| # | Command | Description | |---|---------|-------------| | 25 | Show Git Config | Name, email, editor, remotes | | 26 | List Remotes | All remote URLs | | 27 | Add Remote | Add a new remote | | 28 | Refresh | Re-fetch and redraw screen |

📖 Docs

| # | Command | Description | |---|---------|-------------| | 29 | Git Docs | Full Git reference with examples (also via gitai --docs) |


📖 Built-in Docs

GitAI ships with a comprehensive built-in Git reference. Access it anytime:

gitai --docs

The docs cover:

| Section | Topics | |---------|--------| | Install Git | macOS, Ubuntu/Debian, Windows | | Global Config | user.name, user.email, init.defaultBranch, core.editor, aliases | | SSH Key Setup | ssh-keygen, ssh-agent, adding key to GitHub, testing | | First Repo | git init → first commit → add remote → push | | Clone | HTTPS and SSH | | Daily Workflow | status, diff, add, commit, push, pull, branches, undo, stash, log, remotes, tags | | Config Options | pull.rebase, push.autoSetupRemote, fetch.prune, aliases | | Conventional Commits | feat, fix, docs, style, refactor, test, chore |


🖥️ Screenshots

AI Commit & Push

AI Security Scan

Built-in Docs


🗂️ Project Structure

gitai/
├── bin/
│   └── gitai.sh          # Main CLI script
├── assets/
│   ├── gitai-banner.jpg
│   ├── gitai-demo.png
│   ├── gitai-ai-commit.png
│   ├── gitai-docs.png
│   └── gitai-security-scan.png
├── package.json
├── LICENSE
└── README.md

🤝 Contributing

Contributions are welcome!

# Fork and clone
git clone https://github.com/<your-username>/gitai.git
cd gitai

# Make it executable
chmod +x bin/gitai.sh

# Link it globally for testing
npm link

# Make your changes...

# Test locally
gitai

# Create a PR

📝 License

MIT — Made with ❤️ by Suhail Roushan


Star this repo if you find it useful!