Universal Git Auto Commit & Push Tool - Smart diff-based commits, one-command setup, GitHub auth - Powered By Programmer Fahim
Project description
GitWizard
Universal Git Commit & Push Automation CLI
Smart Diff-Based Commits • One-Command Setup • GitHub Auth • v1.0.0
Official Documentation
Full Documentation: gitwizard.fahim.website
What is GitWizard?
GitWizard is a professional-grade Python CLI tool that fully automates Git commit generation, pushing, and repository management. It is designed for developers who want to save time by automating repetitive git operations while maintaining a clean and meaningful commit history.
Whether you are starting a brand new project or managing an existing repository, GitWizard provides powerful commands to handle everything from initial GitHub setup to smart diff-based commit message generation. The tool analyzes your actual code changes and creates descriptive commit messages automatically, detects word-level replacements like variable renames, and supports both automated and manual commit workflows.
The tool supports over 240+ programming and scripting languages across every major category, making it truly universal for modern development environments. It works entirely locally without sending any code to external servers, requires no API tokens, and is compatible with Windows, macOS, and Linux.
Key Features
- GitHub Authentication Integration — Automatic VS Code and GitHub CLI authorization check with interactive setup guidance for first-time users
- One-Command Project Setup —
gitwizard setuphandles everything: git init, file staging, commit creation, remote connection, and push to GitHub in a single interactive flow - Smart Diff-Based Commit Messages — Automatically analyzes
git diffoutput to generate meaningful, descriptive commit messages based on what actually changed in your code - Word Replacement Detection — Detects when text has been renamed or replaced (e.g., renaming a variable from
FahimtoHasib) and includes it in the commit message - Atomic Per-File Commits — The
--atomicflag creates a separate, individual commit for each file change, keeping your git history clean and granular - Bulk Auto-Commit Generator — Generate multiple automated commits with customizable delay, message templates, and optional auto-push for repository activity
- Both Automation and Manual Modes — Use fully automatic commit message generation or provide your own custom messages at any time
- 240+ Language Support — Intelligently detects programming languages and applies the correct comment syntax for auto-commit operations across 240+ file types
- Dry-Run Simulation — Preview what would happen without making any actual changes to your repository
- Real-Time Progress Bar — Beautiful ASCII progress bar showing commit generation progress in real time
- Safe Interrupt Handling — Gracefully handles Ctrl+C interrupts at any point without leaving your repository in a broken state
- Fully Local Execution — All operations run locally on your machine. No code is sent to any external server
- No API Tokens Required — Uses your existing Git and GitHub CLI configuration. No extra setup needed
- Cross-Platform Compatible — Works seamlessly on Windows, macOS, and Linux with automatic color detection
Installation
Install from PyPI:
pip install gitwizard-pro
Requirements:
- Python 3.7 or higher
- Git installed and available in your system PATH
- GitHub CLI (
gh) recommended for authentication features (install from cli.github.com)
Upgrade from a previous version:
pip install gitwizard-pro --upgrade
Quick Start
1. First-Time Setup (New Project)
If you have a project that is not yet connected to GitHub, the setup command handles everything:
gitwizard setup
This interactive command guides you through:
| Step | Action |
|---|---|
| 1 | Check GitHub Authentication — Verifies if you are logged into GitHub CLI. If not, it guides you through the authentication process step by step |
| 2 | Initialize Git Repository — Runs git init if the project is not already a git repository |
| 3 | Stage All Files — Runs git add . automatically to stage every file in your project directory |
| 4 | Create Commit — Prompts you for a commit message (provides a timestamp-based default) and creates the initial commit |
| 5 | Connect Remote — Prompts you for your GitHub repository URL and configures it as the origin remote |
| 6 | Push to GitHub — Pushes the commit to GitHub automatically. If the regular push fails (common for new empty repos), it tries a force push as a fallback |
You do not need to type a single git command. The entire process is fully automated and interactive.
2. Smart Push (Day-to-Day Usage)
After the initial setup, just make changes to your code and run:
gitwizard push
The tool will:
- Automatically run
git add .to stage all changes - Parse the
git diffoutput to understand exactly what changed - Generate a meaningful, descriptive commit message based on the actual changes
- Create the commit and push it to the remote repository
With a custom commit message:
gitwizard push -m "fix: resolve login bug"
Atomic commits (one per file):
gitwizard push --atomic
Commit locally without pushing:
gitwizard push --no-push
3. Bulk Auto-Commit (Generate Repository Activity)
Generate multiple automated commits for repository activity:
gitwizard auto --count 10
gitwizard auto --count 5 --push
gitwizard auto --count 3 --dry-run
Command Reference
gitwizard setup
Interactive project setup. Connects your local project to GitHub in one command.
gitwizard setup
| Step | Action | Details |
|---|---|---|
| 1 | Check GitHub authentication | Prompts login if not authenticated |
| 2 | Initialize git repository | Runs git init (skips if already a repo) |
| 3 | Stage all files | Runs git add . |
| 4 | Create commit | Asks for commit message |
| 5 | Connect remote | Asks for GitHub repo URL |
| 6 | Push to GitHub | Commits and pushes automatically |
gitwizard push
Smart commit and push based on detected code changes.
gitwizard push # Auto-generate commit message
gitwizard push -m "message" # Custom commit message
gitwizard push --atomic # Separate commit per file
gitwizard push --no-push # Commit only, don't push
| Flag | Description |
|---|---|
-m, --message |
Provide a custom commit message instead of auto-generation |
--atomic |
Create a separate commit for each changed file |
--no-push |
Commit locally without pushing to the remote |
How auto-generated commit messages work:
The tool runs a comprehensive analysis of your git diff output. It parses every changed line, categorizes the type of change, and generates a descriptive commit message using conventional commit format. Here are examples of what it generates:
| Change Type | Generated Message Example |
|---|---|
| Word replaced in code | update: replace 'Fahim' with 'Hasib' in main.py |
| New file added | feat: add config.py |
| File deleted | remove: delete old_script.js |
| Import statements changed | refactor: update imports in utils.py |
| Function or class modified | update: modify login in auth.py |
| Function or class removed | update: remove calculate from math_utils.py |
| Configuration file changed | config: modify settings.yaml (+3/-1) |
| Test file changed | test: modify test_auth.py (+5/-2) |
| Documentation file changed | docs: modify README.md (+12/-3) |
| Dependency file changed | deps: modify requirements.txt (+1/-1) |
| Multiple files changed | update: modify 3 file(s) [main.py, app.py, utils.py] (+12/-3) |
| All new files | feat: add 5 new file(s) (config.py, utils.py, ...) |
| All deleted files | remove: delete 3 file(s) (old.py, backup.py, ...) |
gitwizard auto --count N
Bulk auto-commit generator. Creates multiple commits by appending safe comment lines to tracked source files. This is useful for generating repository activity with realistic-looking commit history.
gitwizard auto --count 5 # Generate 5 auto commits
gitwizard auto --count 10 --push # With auto-push after each commit
gitwizard auto --count 3 --dry-run # Preview mode (no actual commits)
gitwizard auto --count 5 --min-delay 1 --max-delay 3 # Custom delay range
gitwizard auto --count 5 -m "update {file}" # Custom message template
| Flag | Default | Description |
|---|---|---|
--count, -c |
(required) | Number of commits to generate |
--min-delay |
2 | Minimum delay between commits in seconds |
--max-delay |
4 | Maximum delay between commits in seconds |
--message, -m |
auto commit at {time} |
Commit message template |
--push, -p |
false | Push to remote after each commit |
--dry-run |
false | Simulate without making actual commits |
Available template variables:
| Variable | Output Example |
|---|---|
{time} |
2025-01-15 14:30:00 |
{iteration} |
3 |
{file} |
src/main.py |
gitwizard auth
Check or set up GitHub / VS Code authentication.
gitwizard auth # Full interactive setup guide
gitwizard auth --check # Quick auth status check
This command checks if the GitHub CLI (gh) is authenticated. The GitHub CLI is the same authentication system used by VS Code's built-in Git integration. If authentication is not configured, the tool provides a step-by-step interactive guide to help you log in, including installation instructions for macOS, Ubuntu, and Windows.
gitwizard help
Show the full command reference with colored output, along with documentation and report issue links.
gitwizard help
Displays all available commands with colored formatting and provides links to the full documentation website.
How Smart Diff Analysis Works
Overview
When you run gitwizard push, the tool performs a multi-step analysis pipeline to generate the best possible commit message:
Step 1: Change Detection
The tool runs git add . to stage all changes, then captures the git diff --cached output. This gives the tool a complete picture of exactly what lines were added, removed, or modified across all files.
Step 2: File Categorization
Each changed file is automatically categorized based on its name and path. Configuration files, test files, documentation files, dependency files, and data files are each recognized and assigned an appropriate commit prefix (config, test, docs, deps, etc.).
Step 3: Word-Level Replacement Detection
The tool compares removed and added lines pair-by-pair to detect specific word or phrase replacements. For example, if you rename a variable from Fahim to Hasib across your codebase, the tool detects this at the word level and generates a message like:
update: replace 'Fahim' with 'Hasib' in main.py
update: replace 'Fahim' with 'Hasib' in config.py
Step 4: Content Analysis
The tool scans the changed content for common patterns like import statements, function definitions, class definitions, and other structural elements. This allows it to generate messages like:
refactor: update imports in utils.py
update: modify calculate_total in invoice.py
Step 5: Commit Message Generation
All the analysis results are combined into a single, descriptive commit message using the conventional commit format (type: description). For multi-file changes, the message includes a summary of how many files changed, which files, and the total addition/deletion count.
Atomic Commit Mode
When you use the --atomic flag, each file's changes become a separate commit with its own auto-generated message. This is useful for creating a clean, granular commit history where each commit represents exactly one logical change. The process is:
- Unstage all files
- Stage only the first file
- Analyze the diff for that file
- Generate a commit message specific to that file's changes
- Commit with the generated message
- Repeat for each changed file
- Push all commits at once
Supported Languages
The auto-commit generator supports 240+ programming and scripting languages with intelligent comment style detection:
| Category | Languages |
|---|---|
| Web Frontend | JavaScript, TypeScript, JSX, TSX, HTML, CSS, SCSS, SASS, LESS, PHP |
| Systems Programming | C, C++, C#, Rust, Go, Zig, Assembly |
| Scripting Languages | Python, Ruby, Bash, Zsh, PowerShell, Perl, Lua, Tcl |
| Mobile Development | Swift, Kotlin, Dart |
| Functional Programming | Haskell, Erlang, Elixir, Clojure, Scala |
| Data & Analysis | SQL, R, MATLAB, CSV, TSV, JSON |
| Configuration | YAML, TOML, INI, XML, JSON |
| IaC / DevOps | Dockerfile, Terraform, Nix, Kubernetes, CI/CD configs |
| Blockchain / Web3 | Solidity, Move, Vyper |
| Low-Level / Hardware | Assembly, VHDL, Verilog, Fortran, Ada, COBOL |
| Niche / Academic | Lean, Coq, Agda, Idris, Mercury, Joy, Forth |
| And 200+ more | Covering every major programming language in existence |
Each language is mapped to its appropriate comment style (hash, slash, dash, html, css, etc.) so that auto-generated comment lines use the correct syntax for the file type.
Security & Safety
- Fully Local Execution — No code is ever sent to any external server. All git operations run directly on your machine using the standard git command-line tool
- No API Tokens Required — The tool uses your existing Git and GitHub CLI configuration. There is no need to create or manage any additional API tokens
- Safe Comment Lines — Auto-generated comment lines are clearly marked with timestamps and are non-intrusive. They do not affect code functionality
- Dry-Run Mode — Preview exactly what would happen without making any actual commits using the
--dry-runflag - Ctrl+C Safety — All long-running operations handle keyboard interrupts gracefully. You can press Ctrl+C at any point and the tool will stop cleanly without leaving your repository in a broken state
- MIT Licensed — Open source and free to use, modify, and distribute
Platform Compatibility
| Platform | Supported | Notes |
|---|---|---|
| Windows | Yes | Requires Git for Windows. Colors auto-disabled in non-terminal environments |
| macOS | Yes | Works with both Intel and Apple Silicon Macs |
| Linux | Yes | Works with all major distributions |
The tool automatically detects whether your terminal supports ANSI color codes and disables colors when running in environments that do not support them (such as CI/CD pipelines or redirected output). You can also manually disable colors by setting the NO_COLOR environment variable.
Requirements
| Requirement | Version | Details |
|---|---|---|
| Python | 3.7+ | Python 3.7, 3.8, 3.9, 3.10, 3.11, 3.12, 3.13 |
| Git | Any recent version | Must be installed and available in your system PATH |
| GitHub CLI | Latest recommended | Required for authentication features. Install from cli.github.com |
Links
| Resource | Link |
|---|---|
| Official Documentation | gitwizard.fahim.website |
| PyPI Package | pypi.org/project/gitwizard-pro |
| GitHub | github.com/devfahimbd |
License
This project is licensed under the MIT License. See the LICENSE file for details.
Powered By Programmer Fahim
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file gitwizard_pro-1.0.0.tar.gz.
File metadata
- Download URL: gitwizard_pro-1.0.0.tar.gz
- Upload date:
- Size: 32.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
130648305869022bc25af77c74f878bd30a3eaf406b84fc6e1b9b579e014d84c
|
|
| MD5 |
1140eea1546648fd95935e5be7a30929
|
|
| BLAKE2b-256 |
606b5a32f3d28751ff076dad970fe0a77f44ea77a9b792087964ff330734b8d5
|
File details
Details for the file gitwizard_pro-1.0.0-py3-none-any.whl.
File metadata
- Download URL: gitwizard_pro-1.0.0-py3-none-any.whl
- Upload date:
- Size: 27.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fdb3e4565d5faeeec8a06dadfc116ffbe0f63c8e086dcd0319a8c77476de89de
|
|
| MD5 |
e3d579203db32bbe6d2fb14c13c2809f
|
|
| BLAKE2b-256 |
c777e151337234597050996fb211f5807f1540ad5e3ba17babeb654f67e928f1
|