git-ark by Sphire

Back up your git repo to multiple remotes.

git-ark backs up branches, tags, and optional bundles to multiple remotes. It keeps the everyday path conservative, then opens up mirror mode, pruning, and provider-aware diagnostics only when you ask for them.

Safe by default

Branches and tags first

Safe mode pushes branches and tags without mirroring every ref.

Visible history

Metadata that remembers

Every run is recorded so status can show the latest backup and a short history.

Gentle warnings

Provider-aware health checks

doctor checks connectivity and points out obvious provider mismatches.

Start here

To get started using git-ark, these are the commands you need to know:

1

Create a starter config

git-ark init writes a commented git-ark.yml you can edit right away.

2

Validate the repo

git-ark validate checks the config, the repo path, and the most obvious safety issues.

3

Dry run once

git-ark backup --dry-run shows the plan without mutating remotes or creating bundles.

4

Run the backup

git-ark backup executes the chosen mode and writes metadata when enabled.

Commands

Small surface area, easy to remember.

  • init - write a starter config
  • validate - check the config and local repo
  • backup - run the backup flow
  • status - inspect current state and backup history
  • doctor - run health and provider diagnostics
  • remotes list - inspect configured remotes
  • remotes sync - align local remotes with config
  • version - print the build version

Useful flags

The ones you will probably touch most often.

--dry-runPreview the plan.
--repoPoint at another repository path.
--configLoad a specific config file.
--jsonEmit machine-friendly output where supported.
--yesSkip mirror confirmation in non-interactive shells.
--prunePrune remote refs in safe mode.

Config snapshot

The config is intentionally plain YAML so humans can skim it quickly.

version: 1
mode: "safe"
remotes:
  github:
    url: git@github.com:example/example-backup.git
    provider: github
options:
  push_branches: true
  push_tags: true
  prune: false
  write_metadata: true
metadata:
  path: .git/git-ark-last-backup.json