Skip to main content

What The Git CLI – snarky Git history sleuth packaged for Python

Project description

What The Git (wtg) 🔍

A snarky but helpful CLI tool to identify git commits, issues, PRs and file changes, and tell you which release they shipped in. Because sometimes you just need to know what the git is going on!

A totally vibe-coded tool, so do not blame me if it hurts your feelings. 😄

PyPI Crates.io CI

Demo

Demo

Try it yourself!

uvx --from wtg-cli wtg https://github.com/go-task/task/issues/1322

Features

  • 🔍 Smart Detection: Automatically identifies what you're looking for (commit hash, issue/PR number, file path, or tag)
  • 🌐 Remote Repository Support: Work with any GitHub repository without cloning it locally
  • 🔗 GitHub URL Parsing: Paste any GitHub URL (commit, issue, PR, file) and wtg figures it out
  • 🎨 Colorful Output: Beautiful terminal output with emojis and colors
  • 😄 Snarky Messages: Helpful error messages with personality
  • 📦 Release Tracking: Finds which release first shipped your commit, with optional pre-release filtering
  • 🎯 Release Checking: Verify if a commit/issue/PR is in a specific release
  • 👤 Blame Info: Shows who's responsible for that pesky bug
  • 🚀 Smart Caching: Efficiently caches remote repositories with minimal disk usage
  • 🌐 Graceful Degradation: Works without network or GitHub remote

Installation

Recommended: Python package

Run the (python) CLI without installing anything permanently:

uvx --from wtg-cli wtg --help

Or install it as a global tool (works on macOS, Linux, and Windows):

uv tool install wtg-cli
wtg --help

Alternative: build/install from source

cargo install wtg-cli

Usage

Local Repository

Simply run wtg with any of the following:

# Find a commit by hash
wtg c62bbcc

# Find an issue or PR
wtg 123
wtg #123

# Find a file
wtg Cargo.toml

# Find a tag
wtg v1.2.3

# Check if a commit is in a specific release
wtg c62bbcc v2.0.0

# Skip pre-releases when finding the first release
wtg c62bbcc -S

# Fetch latest tags from remote before querying
wtg c62bbcc --fetch

Remote Repository

Query any GitHub repository without cloning it first:

# Using -r flag with owner/repo
wtg -r astral-sh/uv 0.5.0

# Using full GitHub URL
wtg -r https://github.com/astral-sh/uv v0.5.0

# Paste any GitHub URL directly
wtg https://github.com/astral-sh/uv/commit/abc123
wtg https://github.com/astral-sh/uv/issues/42
wtg https://github.com/astral-sh/uv/pull/123
wtg https://github.com/astral-sh/uv/blob/main/README.md

Note: Remote repositories are cached in your system's cache directory for faster subsequent queries. The cache uses --filter=blob:none (Git 2.17+) for minimal disk usage, with automatic fallback to bare clones on older Git versions. On macOS this lives under ~/Library/Caches/wtg/repos, on Linux it defaults to ~/.cache/wtg/repos, and on Windows it follows %LOCALAPPDATA%\wtg\repos.

Output Examples

Commit

🔍 Found commit: c4e0cc8e98d3

💻 The Commit:
   Hash: c4e0cc8
   👤 Who wrote this gem:
      mishamsk (5206955+mishamsk@users.noreply.github.com)
      🔗 https://github.com/mishamsk
   📝 ⬇️ reduce msrv
   📅 2024-11-07 03:37:26
   🔗 https://github.com/mishamsk/sas-lexer/commit/c4e0cc8e98d3e786916ac811c5617ecb68d1a6fd

📦 First shipped in:
   🎉 rust-v1.0.0-beta.3 (rust-v1.0.0-beta.3)
   📅 2024-11-08 03:03:21 U
   🔗 https://github.com/mishamsk/sas-lexer/releases/tag/rust-v1.0.0-beta.3

GitHub Authentication

For better rate limits, set a GitHub token:

  1. Environment variable (recommended):

    export GITHUB_TOKEN=ghp_your_token_here
    
  2. GitHub CLI: wtg automatically reads from ~/.config/gh/hosts.yml if you have gh installed

  3. Anonymous: Works without auth but has lower rate limits (60 requests/hour)

How It Works

  1. Opens your git repository
  2. Tries to identify the input type (commit, issue, file, tag)
  3. Fetches additional info from GitHub API if available
  4. Finds the closest release that contains the commit
  5. Displays everything in a beautiful, colorful format

Limitations

  • Only supports GitHub (GitLab and others coming... maybe?)
  • Squashed commits detection not yet implemented
  • No TUI mode (planned for future)

License

MIT

Contributing

Found a bug? Want to add a snarky message? PRs welcome! Just make sure to keep the snark levels high and the code quality higher.

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

wtg_cli-0.3.0.tar.gz (95.3 kB view details)

Uploaded Source

Built Distributions

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

wtg_cli-0.3.0-cp314-cp314-win_amd64.whl (4.3 MB view details)

Uploaded CPython 3.14Windows x86-64

wtg_cli-0.3.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.4 MB view details)

Uploaded CPython 3.14manylinux: glibc 2.17+ x86-64

wtg_cli-0.3.0-cp314-cp314-macosx_11_0_arm64.whl (3.7 MB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

wtg_cli-0.3.0-cp313-cp313-win_amd64.whl (4.3 MB view details)

Uploaded CPython 3.13Windows x86-64

wtg_cli-0.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.4 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

wtg_cli-0.3.0-cp313-cp313-macosx_11_0_arm64.whl (3.7 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

wtg_cli-0.3.0-cp312-cp312-win_amd64.whl (4.3 MB view details)

Uploaded CPython 3.12Windows x86-64

wtg_cli-0.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.4 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

wtg_cli-0.3.0-cp312-cp312-macosx_11_0_arm64.whl (3.7 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

wtg_cli-0.3.0-cp311-cp311-win_amd64.whl (4.3 MB view details)

Uploaded CPython 3.11Windows x86-64

wtg_cli-0.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (6.4 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

wtg_cli-0.3.0-cp311-cp311-macosx_11_0_arm64.whl (3.7 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

File details

Details for the file wtg_cli-0.3.0.tar.gz.

File metadata

  • Download URL: wtg_cli-0.3.0.tar.gz
  • Upload date:
  • Size: 95.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0.tar.gz
Algorithm Hash digest
SHA256 6200e8ffa6eb018fb3c064819be605e295e7bfecb55de280ccb659fd77d5ac78
MD5 a268d59de6f4ec44d1c1427dabf37bd9
BLAKE2b-256 d9a7fbb8a464e4652ba218f221f7632e5e6d7aa0f7d7a01a32a2658a00801264

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 4.3 MB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 71d35a9038dd473f52f2e38e5d87fad168104e0e01cb46bd2b4165ae14846183
MD5 31a62938666bce14e00707cf4811c387
BLAKE2b-256 45c697ead4811b2e32cd8bb9c81c06ea72b051966cc25f7725dbf815038cbaed

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 6.4 MB
  • Tags: CPython 3.14, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 46771e20728122f8b5853f807c0ca3f70b10ae13d7b71ea3bccc9eb0e0d5984b
MD5 99cbe1969064cf6ae5c0019d3910e0e1
BLAKE2b-256 dff0f8dd25de9bbb257913cf03c80585781ed20eb7667a3d24db3dbbed0f991d

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp314-cp314-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 3.7 MB
  • Tags: CPython 3.14, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 e1fd326790fc2b3a86d4d506f25da8027c6f8e621358d374dcc4cb3fbb1da7ba
MD5 574c73c31508037b6bf96f9155f9db61
BLAKE2b-256 39ed8c5c0feb4f461eeef2d60e324d05eca797206f970d8356bef106bf8270a7

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 4.3 MB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 4571b82869542b8989b60492b9d4bf3de011ed04ee43c3a24045b0a4716c681a
MD5 ede18a6db204f5880e4132a14652acbd
BLAKE2b-256 c4adb99e4e4777106bbfcca425029058be8b8fbe0f77c8eb2a5fb3d5ff096163

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 6.4 MB
  • Tags: CPython 3.13, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 9483d860f9475d03744638da1a7534182c9fcbcfcd9e0594e2785b99cfebfa3b
MD5 c08dcda28faa2ddc1b939ee4ba34148c
BLAKE2b-256 475dcc4d6210960850242b9e0458975af6fb1dd6f6c4285d330fc120864cb18a

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp313-cp313-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 3.7 MB
  • Tags: CPython 3.13, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 44ce2051a8ce6e6ca49983f9bcb109e5309d91d12c200e46f49b594802357036
MD5 7b90295e60840639baee9d4c97c72e6c
BLAKE2b-256 31b3b6d69383bb3a80ea71397d62037af8d72d7f4bb7d3d596b582163ab1008b

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 4.3 MB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 2a4eca2e5bef2ea700cc2bc817c1a8601c1f7b9f5daf9f0af9bf4472567e6c58
MD5 4d8429d72ae25420bc81d8f275a7e9c2
BLAKE2b-256 41e07b3e9562cb6147f05aa3fff365471ca25a37e02a06a8d84b6f8fe24a65c6

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 6.4 MB
  • Tags: CPython 3.12, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3ca4e7d0d41f0921fb35fbc157364c5bc77273cff627e28b0b9f2710c0877c9a
MD5 da89450ba0968db384c573bb31a2d117
BLAKE2b-256 71bca7d757c618647a81502dee3824bf549e2000ece72730221bcf8f976414c3

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp312-cp312-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 3.7 MB
  • Tags: CPython 3.12, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ccaf9803a8dfce6a083278f8a44a3424c12312e40964f74e0eaa7c665657f00d
MD5 c522c01e9a86f85ac42cbe7df0cb46e0
BLAKE2b-256 98809432a50de67c09b7971aa4c1a4b5a48e7178e6810c9fd36a3d7f74ac6746

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 4.3 MB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 1082dbe98bfd5861f8de51de177cdc03fd1b0dd5a23955c075e99988b0b91742
MD5 07e7e28b705b07acb1cfb7be05ac0e29
BLAKE2b-256 6a0c84dd0546b33c401075f23feb04995cf6839bd134f4ae71cb598a30b66358

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
  • Upload date:
  • Size: 6.4 MB
  • Tags: CPython 3.11, manylinux: glibc 2.17+ x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3592452579889bcafda7be82ec4137a557c534e206ee55788dbf9a65a6db26bb
MD5 6548c4d992972f52dee431508bd484cb
BLAKE2b-256 4c04f697e30780be88dd77c2fc9be1db7cc3e7ed283b1d5ef319acbca43f3fb7

See more details on using hashes here.

File details

Details for the file wtg_cli-0.3.0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

  • Download URL: wtg_cli-0.3.0-cp311-cp311-macosx_11_0_arm64.whl
  • Upload date:
  • Size: 3.7 MB
  • Tags: CPython 3.11, macOS 11.0+ ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.26 {"installer":{"name":"uv","version":"0.9.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for wtg_cli-0.3.0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 3f45bb238389d25d8505fe33e04c96a8935049b28417595b92385b2f6e597a33
MD5 ca64431a77a4964e1b6fcb42e186e6f9
BLAKE2b-256 10ddeed4f2d67177f56282477e85f83d87d940bc3ccf2fc53cf35dc9cb3e03ed

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