-
Notifications
You must be signed in to change notification settings - Fork 0
Getting Started
This guide walks through creating your first GitBack backup.
Run:
gitback initInitialization:
- Creates the configuration
- Stores your GitHub token
- Validates GitHub API access
- Creates required directories
Expected output:
✓ configuration created
✓ GitHub authentication verified
Discover repositories and Gists accessible to your GitHub account:
gitback discoverGitBack stores the discovered inventory locally:
~/.local/share/gitback/state/
├── repositories.txt
└── gists.txt
Create or update local Git mirrors:
gitback syncGitBack performs incremental updates when mirrors already exist.
Example:
[SYNC] FlareXes/gitback
[SYNC] FlareXes/assets
[GIST] 9565facfb6541360f7f7aeb2eeceb258
Mirrors are stored in:
~/.local/share/gitback/mirrors/
├── repositories/
└── gists/
Create a compressed backup archive:
gitback snapshotSnapshot files are stored in:
~/.local/share/gitback/snapshots/
Example:
2026-06-17T14-30-00Z.tar.zst
2026-06-17T14-30-00Z.tar.zst.sha256
To continue snapshot creation even if assets failed during the last sync:
gitback snapshot --forceReview backup status:
gitback healthExample:
{
"status": "healthy",
"repositories": {
"total": 42,
"healthy": 42
},
"gists": {
"total": 12,
"healthy": 12
}
}Health reports include:
- Repository status
- Gist status
- Snapshot information
- Storage usage
- Recommendations
A common backup workflow is:
gitback discover
gitback sync
gitback snapshot --force
gitback healthFor unattended environments:
- Run
discoverperiodically - Run
syncregularly - Run
snapshot --forceafter sync - Monitor
health
GitBack automatically recreates missing runtime directories when possible:
mirrors/
snapshots/
state/
tmp/
This helps recover from accidental directory deletion without manual intervention.
Confirm mirrors exist:
find ~/.local/share/gitback/mirrorsConfirm snapshots exist:
ls ~/.local/share/gitback/snapshotsVerify snapshot integrity:
sha256sum -c snapshot.tar.zst.sha256Expected result:
snapshot.tar.zst: OK
Continue with: