Holocron: The Ultimate Git Mirroring Tool
Project description
Holocron
The "Ultimate" Git Mirroring Tool
/\
/ \
/ /\ \
/ / \ \
/ / \ \
/_/______\_\
\ \ / /
\ \ / /
\ \ / /
\ \/ /
\ /
\/
Holocron is a powerful Python application designed to mirror your GitHub repositories to a local directory or a self-hosted GitLab instance. It supports parallel syncing, continuous watch mode, and local-only backups (no GitLab required).
Features
- Parallel Syncing: Sync multiple repositories concurrently for maximum speed.
- Continuous Watch Mode: Polls for changes and syncs only when necessary (smart redundancy checks).
- Two-Way Mirroring: Creates a bare mirror (
.gitfolder) for safety AND an optional checkout for visibility. - Dockerized: Runs as a lightweight container.
- Backup Level:
- Full: GitHub -> Local -> GitLab
- Backup-Only: GitHub -> Local (No GitLab token needed)
Quick Start
1. Docker (Recommended)
docker-compose up -d --build
This starts Holocron in watch mode.
2. Manual Run
# Install dependencies
uv sync
# Run a one-time backup of all your repos locally (visible files)
export GITHUB_TOKEN=your_token
uv run python src/holocron.py --backup-only --checkout --concurrency 10
Configuration
Holocron uses environment variables for secrets:
| Variable | Description | Required |
|---|---|---|
GITHUB_TOKEN |
Your GitHub Personal Access Token (repo scope) | Yes |
GITLAB_TOKEN |
Your GitLab Personal Access Token (api scope) | No (if --backup-only) |
GITLAB_API_URL |
URL to your GitLab API (default: http://gitlab.local/api/v4) |
No |
Command Line Arguments
| Flag | Default | Description |
|---|---|---|
--watch |
False | Run continuously in a loop |
--interval |
60 | Seconds to sleep between checks in watch mode |
--window |
60 | Sync only repos pushed within the last N minutes |
--backup-only |
False | Mirror locally only, do not push to GitLab |
--checkout |
False | Create a visible working directory alongside the mirror |
--concurrency |
5 | Number of parallel sync threads |
--storage |
./mirror-data |
Directory to store repositories |
--dry-run |
False | Print what would happen without doing it |
--verbose |
False | Enable detailed debug logging |
Development
Run tests with coverage:
uv run pytest --cov=src
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
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 holocron_sync-0.1.0.tar.gz.
File metadata
- Download URL: holocron_sync-0.1.0.tar.gz
- Upload date:
- Size: 53.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d7ab3a527df3396a869b4ef3c00e57590d9559a681e7f464c9dc1c01c8fd431f
|
|
| MD5 |
990a78b1514afa890db5b3a5a604a5f4
|
|
| BLAKE2b-256 |
d53214062779a10098347e2f45f08aa7ddd17cb6d3c6c55a10be053574a47990
|
Provenance
The following attestation bundles were made for holocron_sync-0.1.0.tar.gz:
Publisher:
publish.yaml on Someniak/holocron
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
holocron_sync-0.1.0.tar.gz -
Subject digest:
d7ab3a527df3396a869b4ef3c00e57590d9559a681e7f464c9dc1c01c8fd431f - Sigstore transparency entry: 757505473
- Sigstore integration time:
-
Permalink:
Someniak/holocron@528f02b93008946631c0f53f7e9d0b7eb9a5c4e5 -
Branch / Tag:
refs/tags/0.0.3 - Owner: https://github.com/Someniak
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yaml@528f02b93008946631c0f53f7e9d0b7eb9a5c4e5 -
Trigger Event:
release
-
Statement type:
File details
Details for the file holocron_sync-0.1.0-py3-none-any.whl.
File metadata
- Download URL: holocron_sync-0.1.0-py3-none-any.whl
- Upload date:
- Size: 9.3 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 |
80971e90a269e4d2a3b29963194528c51cb4abbb00ce4acb4061282a83a91c94
|
|
| MD5 |
ae30efbb990ae337757778f86d49ce2d
|
|
| BLAKE2b-256 |
73a3bf2a2b0d6ab693fa39123c0f650fdd70cef9e8b0adf3f76fda4ced8026e2
|
Provenance
The following attestation bundles were made for holocron_sync-0.1.0-py3-none-any.whl:
Publisher:
publish.yaml on Someniak/holocron
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
holocron_sync-0.1.0-py3-none-any.whl -
Subject digest:
80971e90a269e4d2a3b29963194528c51cb4abbb00ce4acb4061282a83a91c94 - Sigstore transparency entry: 757505475
- Sigstore integration time:
-
Permalink:
Someniak/holocron@528f02b93008946631c0f53f7e9d0b7eb9a5c4e5 -
Branch / Tag:
refs/tags/0.0.3 - Owner: https://github.com/Someniak
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish.yaml@528f02b93008946631c0f53f7e9d0b7eb9a5c4e5 -
Trigger Event:
release
-
Statement type: