Visualize git history as per-machine tunnels in your terminal
Project description
git-tunnel
Visualize your git history as per-machine tunnels in the terminal.
If you work across multiple machines like me — a MacBook, a Workstation, a Server — git
log treats them all the same which can be very annoying at some points. git-tunnel splits each machine into its own
colored column so you can see at a glance where every commit was made.
────────────────────────────────────────────────────────────────────────────────
TIME │ pre git-tunnel │ MacBook │ Workstation │ HASH
────────────────────────────────────────────────────────────────────────────────
2 hours ago │ · · · · · · · · · · · · · · │ WIP: invoice route │ · · · · · · · · · · · · · · │ 2c4930f
3 hours ago │ · · · · · · · · · · · · · · │ · · · · · · · · · · · · · · │ finished validation │ 6f46c9f
1 day ago │ added model │ · · · · · · · · · · · · · · │ · · · · · · · · · · · · · · │ fd7bcad
1 day ago │ initial setup │ · · · · · · · · · · · · · · │ · · · · · · · · · · · · · · │ f3bc95b
────────────────────────────────────────────────────────────────────────────────
■ pre git-tunnel ■ MacBook ■ Workstation
Commits made before git-tunnel was installed appear in a plain white
pre git-tunnel column — no history rewriting, no warnings.
Install
The recommended way to install git-tunnel is with pipx or uv — both install it into an isolated environment and expose the git-tunnel command globally. This avoids the externally-managed-environment error you get with bare pip on Ubuntu 23.04+ and other modern Linux distros.
pipx (recommended for most users):
pipx install git-tunnel
uv (if you already use uv):
uv tool install git-tunnel
pip (virtualenv or older systems only):
pip install git-tunnel
On Ubuntu 23.04+, Debian 12+, and similar distros, using
pip installsystem-wide will likely fail with anexternally-managed-environmenterror. Usepipxoruv tool installinstead.
Don't have pipx? Install it first:
# Ubuntu / Debian
sudo apt install pipx
pipx ensurepath
# macOS
brew install pipx
pipx ensurepath
Install (once per machine)
Run the interactive install:
git-tunnel install
This will:
- Ask for a device name (e.g.
MacBook,Workstation,Server) - Set
git config --global user.device - Install the
prepare-commit-msghook globally - Point
git config --global core.hooksPathat the hook
From this point on, every commit you make will automatically get a
[device:YourDevice] tag appended to the message — silently, without
you doing anything.
Usage
Inside any git repo:
# Compact view (messages truncated)
git-tunnel
# Full view (complete commit messages)
git-tunnel --all
Not sure what's available? Run:
git-tunnel --help
How it works
git-tunnel uses a global prepare-commit-msg hook that appends a
[device:X] tag to every commit message, where X comes from
git config --global user.device.
Your user.name is never touched — it stays clean for collaboration.
The device tag lives in the commit message body and is stripped from
the display in the tunnel view.
Multiple machines
Set a different device name on each machine:
# MacBook
git-tunnel install # enter "MacBook" when prompted
# Workstation
git-tunnel install # enter "Workstation" when prompted
# Server
git-tunnel install # enter "Server" when prompted
Since the hook is global, it applies to every repo on that machine automatically.
Zero dependencies
git-tunnel uses only the Python standard library and git itself.
No third-party packages required.
License
MIT
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 git_tunnel-0.1.2.tar.gz.
File metadata
- Download URL: git_tunnel-0.1.2.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
2caef67475d8bdeef90f690cc297981c95e88f13223f8fb18d4d9aead203ca71
|
|
| MD5 |
be5320bdda530a1b66bf9dc6cbd3a96f
|
|
| BLAKE2b-256 |
e33a0adcef0f5df5a8d02a68e73bfb48025f97b9fe6ba1132135624dd6b9ba85
|
Provenance
The following attestation bundles were made for git_tunnel-0.1.2.tar.gz:
Publisher:
publish.yml on YounesHB92/git-tunnel
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
git_tunnel-0.1.2.tar.gz -
Subject digest:
2caef67475d8bdeef90f690cc297981c95e88f13223f8fb18d4d9aead203ca71 - Sigstore transparency entry: 1245572512
- Sigstore integration time:
-
Permalink:
YounesHB92/git-tunnel@3652b42f670209cc0456575aabfdad6a840135c1 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/YounesHB92
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@3652b42f670209cc0456575aabfdad6a840135c1 -
Trigger Event:
push
-
Statement type:
File details
Details for the file git_tunnel-0.1.2-py3-none-any.whl.
File metadata
- Download URL: git_tunnel-0.1.2-py3-none-any.whl
- Upload date:
- Size: 8.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
6a857ab122352921169236d289058e1521c1a045d849078791bbe2a866ec39ce
|
|
| MD5 |
8f5117fdae22eb5565e88cdd2ccc9149
|
|
| BLAKE2b-256 |
6357a9f44dc4644ec401e9b498462f6e54e4e328a20c8639d3d74f3ba7d1ce82
|
Provenance
The following attestation bundles were made for git_tunnel-0.1.2-py3-none-any.whl:
Publisher:
publish.yml on YounesHB92/git-tunnel
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
git_tunnel-0.1.2-py3-none-any.whl -
Subject digest:
6a857ab122352921169236d289058e1521c1a045d849078791bbe2a866ec39ce - Sigstore transparency entry: 1245572530
- Sigstore integration time:
-
Permalink:
YounesHB92/git-tunnel@3652b42f670209cc0456575aabfdad6a840135c1 -
Branch / Tag:
refs/tags/v0.1.2 - Owner: https://github.com/YounesHB92
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yml@3652b42f670209cc0456575aabfdad6a840135c1 -
Trigger Event:
push
-
Statement type: