Written in C++ | 3mb

github_logonpm_logo
>

Conventional commits
zero effort

XOMMIT is a CLI tool that writes conventional commits from file diffs

██╗██╗██████╗███╗███╗███╗███╗██╗████████╗
╚██╗██╔╝██╔═══██╗████╗████║████╗████║██║╚══██╔══╝
╚███╔╝██║██║██╔████╔██║██╔████╔██║██║██║
██╔██╗██║██║██║╚██╔╝██║██║╚██╔╝██║██║██║
██╔╝██╗╚██████╔╝██║╚═╝██║██║╚═╝██║██║██║
╚═╝╚═╝╚═════╝╚═╝╚═╝╚═╝╚═╝╚═╝╚═╝

$

Install

XOMMIT uses Groq to turn your vague message into a commit message. It's free, you just need an API key. Takes like a minute.

  1. Go to console.groq.com and create an account. You can sign up with Google, GitHub or email, no card needed.
  2. Once you're in, open the API Keys page from the sidebar.
  3. Click Create API Key, give it any name (like xommit) and submit.
  4. Copy the key it shows you. It starts with gsk_ and you only see it once, so grab it right away. Lost it? Just delete it and make a new one.

Now install xommit below, then run this and paste the key when it asks:

terminal
xommit --connect

You can re-run xommit --connect anytime to change the key, or wipe it with xommit --reset.

>

You need to have Node.js installed.

terminal
npm install -g @abhraneeldhar7/xommit

This adds the xommit command to your PATH globally. Package page: @abhraneeldhar7/xommit on npm

If you get a permission error, use:

cmd
sudo npm install -g @abhraneeldhar7/xommit

Or fix your npm permissions: docs.npmjs.com/resolving-eacces-permissions-errors

Verify it worked:

cmd
xommit --version

Works on Linux and macOS. You need curl or wget (and git installed).

terminal
curl -fsSL https://raw.githubusercontent.com/abhraneeldhar7/xommit/master/cli-tool/scripts/install.sh | bash

What it does:

  1. Detects your OS (Linux/macOS) and architecture (x64/arm64)
  2. Downloads the correct binary from GitHub Releases
  3. Makes it executable
  4. Installs it to /usr/local/bin (may ask for sudo)
  5. Prints next steps

Windows users: This installer does not work on Windows. Use npm or PowerShell instead.

Verify:

terminal
xommit --version

Works on Windows (PowerShell 5.1+). Needs git installed.

powershell
irm https://raw.githubusercontent.com/abhraneeldhar7/xommit/master/cli-tool/scripts/install.ps1 | iex

What it does:

  1. Downloads xommit.exe from GitHub Releases
  2. Installs it to %LOCALAPPDATA%\Programs\xommit
  3. Adds the install directory to your user PATH
  4. Prints next steps

Restart your terminal after installation so the PATH changes take effect.

Verify:

powershell
xommit --version

Build from source. You need a few things installed first:

1. Clone the repo from github.com/abhraneeldhar7/xommit:

terminal
git clone https://github.com/abhraneeldhar7/xommit.git
cd xommit/cli-tool

2. Install dependencies (for the build script):

terminal
npm install

3. Build:

terminal
node scripts/build.js

This compiles src/main.cpp into a binary in the bin/ directory:

  • Windows: bin/xommit.exe
  • Linux: bin/xommit
  • macOS: bin/xommit-macos

4. Add it to your PATH:

Linux:

terminal
sudo cp bin/xommit /usr/local/bin/

macOS:

terminal
sudo cp bin/xommit-macos /usr/local/bin/xommit

Windows (PowerShell):

powershell
New-Item -ItemType Directory -Force "$env:LOCALAPPDATA\Programs\xommit"
Copy-Item bin\xommit.exe "$env:LOCALAPPDATA\Programs\xommit\"

Or add cli-tool/bin/ to your PATH permanently.

5. Connect your Groq key:

terminal
xommit --connect

Compiler requirements:

  • Windows: MinGW-w64 (g++)
  • Linux: sudo apt install g++
  • macOS: xcode-select --install

Commands

xommit <your_message_here>

or just xommit works just fine

--help

show tutorial

--connect

paste in your groq key

--reset

remove groq apikey

--update

download latest release from github

--version

show version

How AI was used in this project

I'm inspired by the black magic @ruben does on twitter. Wanted to move past the dsa questions, so used AI to set-up the skeleton and iterated over it. I'm using this project to learn cpp in-depth, wanted to share a cool tool.

Made by abhraneel