A complete Version Control System built from scratch in Python.
DING is an version control system developed as part of OpenCode by IIITA.
The goal of this project is to build a VCS that implements most of the features git
DING focuses on teaching core concepts such as content-addressable storage, snapshots, commits, branching, diffs, and logs - all through readable, well-structured Python code.
If you've ever wondered “What actually happens when I run git commit?”, DING is for you.
- Build a fully functional VCS, not a mock or toy model
- Keep the implementation simple, readable, and hackable
- Encourage contributors to learn by building, not just using tools
- Initialize a DING repository inside any directory
- Creates internal metadata and object storage
- Inspired by Git’s
.gitstructure
- Content-addressable storage using hashes
- Stores:
- Blobs (file contents)
- Trees (directory snapshots)
- Commits (project states)
- Snapshot-based commits
- Commit metadata (message, parent, timestamp)
- Linear history traversal
- Commit logs similar to
git log
- Lightweight branch references
- HEAD pointer management
- Switch between branches safely
- Show changes between commits
- Working directory vs last commit
- Track modified, added, and deleted files
Before starting - check out our CONTRIBUTING.md to get a refresher on contribution and general workflow.
- Python 3.x
NONE, build from scratch just using std
.
├── setup.py
└── ugit
├── base.py
├── cli.py
├── data.py
├── diff.py
└── remote.py