Skip to main content

Git subcommand for named changelist support. Group working directory files by intent, then stage, commit, or branch by changelist.

Project description

git-cl

A pre-staging layer for organising changes in Git

Tutorial Paper Story DOI PyPI Tests GitHub stars

git-cl is a command-line tool that brings changelist support to Git, inspired by Subversion. It adds a pre-staging review layer that lets you organise modified files into named groups before staging or committing. Changelists can be stashed selectively and promoted to dedicated branches — enabling a late-binding branching workflow where the branch decision follows the code, not the other way around.

git‑cl operates on file level. It groups and stages whole files by intent, while leaving patch‑level editing to other Git tools.

Why git-cl?

Workflow

  • Pre-staging review: group changed files by intent before staging
  • Organise multiple concerns on a single branch
  • Stage and commit changes by intent
  • Stash changelists and resume work later
  • Late-binding branching: promote a changelist to a dedicated branch

Technical

  • Local-only metadata (.git/cl.json)
  • Simple CLI: git cl <command>
  • Interoperable with community VS Code extension

Demo

git-cl demo: creating changelists, viewing status, and branching

Quick Start

Install via pip

pip install git-changelists

The PyPI package is named git-changelists to avoid namespace conflicts; it installs the git-cl command.

Install via wget

mkdir -p ~/bin
wget https://raw.githubusercontent.com/BHFock/git-cl/main/git-cl -O ~/bin/git-cl
chmod +x ~/bin/git-cl

Make sure ~/bin is listed in your $PATH.

Verify installation

git cl --version
git cl help

Use changelists inside a Git repository

git cl add fixup file1.py
git cl status
git cl commit fixup -m "Fix file1"

Common Commands

# Add files to a changelist
git cl add docs-fix README.md docs/index.md

# See changes grouped by changelist
git cl status

# Stage or commit changelists
git cl stage docs-fix
git cl commit docs-fix -m "Update documentation layout and intro"

# Keep the changelist after committing
git cl commit docs-fix -m "Fix bug" --keep

# Remove a file from its changelist
git cl remove README.md

# Delete a changelist
git cl delete docs-fix

# Late-binding branching: create a branch from a changelist (auto-stash/unstash)
git cl br docs-fix

Documentation

📘 Tutorial: Guide with examples and FAQ

📘 Design Notes: Technical architecture

📘 Tests: Test suite and shell walkthroughs

📘 Why git-cl?: History and motivation

📘 Paper: Design, workflow, and related work

Notes

  • Requires Python 3.9+ and Git
  • Local-only; designed for single-user workflows
  • Always inspect downloaded scripts before executing, see source
  • For security concerns, see SECURITY

License

BSD 3-Clause — see LICENSE | CONTRIBUTING

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_changelists-1.1.6.tar.gz (51.1 kB view details)

Uploaded Source

Built Distribution

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

git_changelists-1.1.6-py3-none-any.whl (31.2 kB view details)

Uploaded Python 3

File details

Details for the file git_changelists-1.1.6.tar.gz.

File metadata

  • Download URL: git_changelists-1.1.6.tar.gz
  • Upload date:
  • Size: 51.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for git_changelists-1.1.6.tar.gz
Algorithm Hash digest
SHA256 35a8c9391a5edd52437e22eb7fccc1d375fec924cb7cd4d82fb8e4022948caf4
MD5 8c334d7ada004e997eef2610b5a78b4a
BLAKE2b-256 520b1545acd2c1f1a882fefa3d663e9cdcfca42d3106edcdb1973a0ac9a25924

See more details on using hashes here.

File details

Details for the file git_changelists-1.1.6-py3-none-any.whl.

File metadata

File hashes

Hashes for git_changelists-1.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 9e1b5429ede8e031f402e8500d9a69a5b9c494f128b1799d06ec9253844a166f
MD5 d0ae6847f564bd73f352e2acdbe9b132
BLAKE2b-256 6eda36044a31abc93a2951cca0bb57702e64e088af13c5e2e8eb53b38845ba40

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