Skip to main content

Automatically generate and commit changes using copilot

Project description

git-copilot-commit

🤖 AI-powered Git commit assistant that automatically generates conventional commit messages using GitHub Copilot.

Features

  • AI-Generated Commit Messages: Uses GitHub Copilot to analyze your staged changes and generate conventional commit messages
  • Message Editing: Edit generated messages using your git-configured editor or commit directly
  • Conventional Commits: Follows the Conventional Commits specification
  • Rich Output: Beautiful terminal output with syntax highlighting and tables

Installation

Install using uv (recommended):

uv tool install git-copilot-commit
# or
uvx git-copilot-commit

Or with pip:

pipx install git-copilot-commit

Prerequisites

  1. GitHub Copilot Access: You need an active GitHub Copilot subscription
  2. Authentication: Authenticate with GitHub Copilot before first use

Quick Start

  1. Authenticate with GitHub Copilot:

    git-copilot-commit authenticate
    
  2. Make some changes in your git repository

  3. Generate and commit:

    git-copilot-commit commit
    

Usage

commit

Automatically commit changes in the current git repository:

git-copilot-commit commit

Options:

  • --all, -a: Stage all files before committing
  • --verbose, -v: Show verbose output with file details
  1. The tool analyzes your changes
  2. Prompts you to stage files (if needed)
  3. Generates an AI-powered commit message
  4. Offers three choices:
    • (c)ommit: Commit with the generated message
    • (e)dit: Edit the message in your git-configured editor
    • (q)uit: Cancel the commit

authenticate

Set up authentication with GitHub Copilot:

git-copilot-commit authenticate

models

List available AI models:

git-copilot-commit models

Examples

Commit all changes with staging prompts:

git-copilot-commit commit --all

Commit with verbose output:

git-copilot-commit commit --verbose

Generated Commit Message Format

The tool follows the Conventional Commits specification:

<type>[optional scope]: <description>

Supported Types:

  • feat: A new feature
  • fix: A bug fix
  • docs: Documentation changes
  • style: Code formatting (no logic changes)
  • refactor: Code restructuring (no behavior changes)
  • perf: Performance improvements
  • test: Adding or updating tests
  • chore: Maintenance tasks (tooling, dependencies, etc.)
  • revert: Reverting previous changes

Example Messages:

  • feat(auth): add user authentication with JWT
  • fix(database): handle connection retries properly
  • docs(readme): update installation instructions
  • refactor(utils): simplify date parsing logic

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

git_copilot_commit-0.1.1.tar.gz (21.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

git_copilot_commit-0.1.1-py3-none-any.whl (10.7 kB view details)

Uploaded Python 3

File details

Details for the file git_copilot_commit-0.1.1.tar.gz.

File metadata

  • Download URL: git_copilot_commit-0.1.1.tar.gz
  • Upload date:
  • Size: 21.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.19

File hashes

Hashes for git_copilot_commit-0.1.1.tar.gz
Algorithm Hash digest
SHA256 9887eb12c61925d32f523a2121a8574479a00efd980dff6c537fdca2d5161a5e
MD5 24e0200de0b5e509106a475941967b51
BLAKE2b-256 42bcdba9c234f43def57c4d61e50476b2ca9892e06eaceff2c9aa42867a5e3a1

See more details on using hashes here.

File details

Details for the file git_copilot_commit-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for git_copilot_commit-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 56008860ba15c7686ce3230bb7da939454f411c78ea646f4b8b7a9a4b23d6be7
MD5 9c7b4c9331bc28d7d66ce2995ec0dc14
BLAKE2b-256 a7c35c65cb5d8940da0d21d0b808e29eb249b179c7e223ca5352e1f9407d9c08

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page