https://github.com/ridit-jangra/forge
Mini git in python.
https://github.com/ridit-jangra/forge
git git-in-python mini-git simple-git
Last synced: about 1 month ago
JSON representation
Mini git in python.
- Host: GitHub
- URL: https://github.com/ridit-jangra/forge
- Owner: ridit-jangra
- License: mit
- Created: 2026-01-31T15:52:39.000Z (about 1 month ago)
- Default Branch: main
- Last Pushed: 2026-01-31T18:40:44.000Z (about 1 month ago)
- Last Synced: 2026-02-01T03:42:31.347Z (about 1 month ago)
- Topics: git, git-in-python, mini-git, simple-git
- Language: Python
- Homepage:
- Size: 35.2 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Forge
**Forge** is a lightweight, Git-like version control system built in Python with a custom remote backend.
It allows you to track files, commit changes, and synchronize repositories with a remote server using a simple CLI.
Forge works together with **Vault**, which acts as the remote storage layer where your repositories, commits, and files are stored.
---
## Architecture Overview
- **Forge** → CLI tool you run locally (version control client)
- **Vault** → Remote server that stores repositories, commits, and file data
When you push a repository using Forge, **your entire repo is stored remotely in Vault**.
Cloning or forking a repo pulls data back from Vault to your local machine.
---
## Features
### Local Version Control
- Initialize a repository (`init`)
- Track files individually or all at once (`add`)
- Remove files from tracking (`remove`)
- Commit changes with messages (`commit`)
- Checkout previous commits (`checkout`)
- List commit history (`list commits`)
- `.forgeignore` support for ignoring files and folders
### Remote (Vault-powered)
- User authentication (`register`, `login`, `logout`)
- Push repositories to the remote Vault server (`push`)
- Clone repositories stored in Vault (`clone`)
- Fork repositories into your account (`fork`)
- List your repositories (`repos`)
- Delete remote repositories (`delete`)
---
## Installation
### Option 1: Python (Development)
This option is recommended if you are developing Forge or running it directly from source.
```bash
git clone https://github.com/ridit-jangra/Forge
cd Forge
pip install -r requirements.txt
python forge.py
```
---
### Option 2: Executable (Recommended)
If you downloaded the compiled executable:
```bash
forge.exe
```
No Python installation or configuration is required.
---
## Vault Configuration
⚠️ **Vault configuration is only required when using Forge via Python (development mode).**
When using the **compiled executable**, Vault configuration is **already set internally**, and you do not need to configure anything.
### Python-only Configuration
Forge connects to Vault using environment variables.
Optional `.env` file:
```env
FORGE_SERVER_URL=http://localhost:8000
FORGE_SESSION=.forge_session
```
If these variables are not set, sensible defaults are used.
---
## Usage
### Initialize Repository
```bash
forge init
```
### Track & Commit
```bash
forge add .
forge commit "Initial commit"
```
### Push to Vault (Remote)
```bash
forge push
```
Your repository, commits, and files are now **stored remotely in Vault**.
---
## Remote Operations
```bash
forge clone /
forge fork /
forge repos
forge delete
```
---
## `.forgeignore`
Example:
```text
node_modules
.env
*.log
dist
```
---
## Example Workflow
```bash
forge init
forge add .
forge commit "Initial commit"
forge push
forge clone 12/sample
```
---
## Limitations
- Text files only
- No branches or merges
- Linear history
- Early-stage project (breaking changes possible)
---
## License
MIT License