Skip to main content

Borg for Dummies

Project description

Easyborg

Easyborg is a simple frontend for the awesome BorgBackup (aka Borg) with fzf for user input.

This project is currently in beta phase.

Tests (Linux) Tests (macOS)

Screenshots

Extract

Demonstration of extract command

Delete

Demonstration of delete command

Setup

Installation

You have the choice between Homebrew / Linuxbrew or Python pipx.

Homebrew / Linuxbrew (recommended)

brew tap sebastianhaberey/easyborg
brew install easyborg

pipx

pipx install easyborg 

NOTE You'll need a Python installation for pipx. Also make sure you have BorgBackup and fzf installed.

Repositories

Easyborg doesn't provide any commands for creating repositories. It's easy to do with Borg, and you only have to do it once. For Easyborg to access a repository, you must set up BORG_PASSCOMMAND or any other of the environment variables Borg supports. If you succeed, you can access your repository without password prompt:

$ export BORG_PASSCOMMAND = "cat /Users/example/passphrase.txt"
$ borg list /Volumes/HD/backup
2025-11-13T17:46:47-F1AC35F6         Thu, 2025-11-13 17:46:47 [7b9fd68dd8e991ea9fd598ca015e10266498afc156969ccdfe67149124fd27cc]
2025-11-14T20:20:25-2965DCFB         Fri, 2025-11-14 20:20:25 [33539a1e5f2b83852cf5396ed442531d6b5d4cb2137522280285725c3ea5df48]
  • If you're asked for a SSH password, set up access to your server via SSH key.
  • If you're asked for a Borg repository password, set up BORG_PASSCOMMAND.

NOTE Be sure to chmod 600 your passcommand file to prevent others from accessing it.

Once that works, you can add the environment variable to Easyborg's configuration file (see below).

Configuration

Minimal configuration example:

backup_folders = [
    "/Users/example/Documents",
]

[environment]
BORG_PASSCOMMAND = "cat /Users/example/passphrase.txt"

[repositories.BACKUP]
type = "backup"
url = "/Volumes/HD/backup"

Call easyborg info to generate a quickstart configuration file with a bunch of other settings for demonstration. The path to the new configuration file will be listed in the output:

$ easyborg info

Configuration:

  Config dir    /Users/user/Library/Application Support/easyborg/default
  Config file   /Users/user/Library/Application Support/easyborg/default/easyborg.toml
  Log dir       /Users/user/Library/Logs/easyborg/default
  Log file      /Users/user/Library/Logs/easyborg/default/easyborg.log
  Log level     INFO
  
...

If you're on a modern terminal, you may be able to click on a path to open it (Ctrl + click on iTerm2). Open the configuration file, keep and change the settings you like, delete those that you don't need. Verify your settings by calling easyborg info again.

Usage

Easyborg currently supports six main commands: backup, archive, restore, extract, delete and replace. Use

easyborg --help

for details on these and some utility commands.

Concept

Easyborg makes a distinction between backup and archive.

Purpose Data Type Data State Trigger Retention
Backup recovery needed for daily work changing automatic days to months
Archive preservation needed for reference stable manual years to forever

Backup

If you enable automatic backups, Easyborg will create a snapshot of all configured folders in each configured backup repository every full hour. Meaning at 12:00, 13:00 and so on. Then, snapshots are pruned to save space. So after the 13:00 snapshot is written, the 12:00 snapshot will be deleted. A selection of snapshots will be retained:

  • the last snapshot of the day for the past seven days
  • one snapshot per week for the past three months

Any snapshot older than three months will be deleted.

NOTE Pruning only occurs when easyborg backup is called, manually or automatically. If you don't call it, your existing snapshots won't be touched.

Archive

With Easyborg you create a snapshot in each configured archive repository whenever you want. For example if you decide to tidy up your Documents folder, a resonable strategy would be:

  1. Delete all files you want to get rid of (especially big files)
  2. Archive the remaining files using easyborg archive
  3. Delete all files you want to keep but don't need for your daily work

That way, you start with a nice clean slate and still have all the documents you might need for later reference stored away in your archive repositories. Of course you can follow a different approach. It's up to you what to archive and when.

NOTE Archive snapshots are never pruned automatically. If you want to delete an archive snapshot, use easyborg delete.

Glossary

Easyborg Meaning Borg
Snapshot immutable point-in-time view of data Archive
Backup Repository storage of snapshots intended for recovery Repository
Archive Repository storage of snapshots intended for preservation Repository
Snapshot Location Borg-style snapshot reference (repository_url::snapshot_name) Archive Location
Repository URL Borg-style repository reference (local or remote) (same)
backup (command) create snapshot in backup repository borg create
archive (command) create snapshot in archive repository borg create
extract (command) fetch selected items from snapshot borg extract
restore (command) fetch entire snapshot borg extract

Relativization

If you backup or archive a folder, e.g.:

/Users/user/Documents

it will be stored in the snapshot as:

Users/user/Documents

When you restore or extract the folder, it will be written to the current working directory:

<CWD>/Users/user/Documents

This is a safety feature. If you do want to overwrite the original folder, you can

a] go to its parent folder (/ in the example) and run the restore action there (not recommended), or b] delete the original folder and move the restored one in its place, or c] use easyborg replace which does b] for you

Disclaimer

Even though I'm doing my best, and there's an automatic test suite that covers the critical functionality on Linux and macOS, errors can happen. Use this application at your own risk. It is highly recommended to start with fresh repositories to avoid data loss.

Expert topics

If you're still here, have a look at the expert topics

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

easyborg-0.12.0.tar.gz (26.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

easyborg-0.12.0-py3-none-any.whl (29.2 kB view details)

Uploaded Python 3

File details

Details for the file easyborg-0.12.0.tar.gz.

File metadata

  • Download URL: easyborg-0.12.0.tar.gz
  • Upload date:
  • Size: 26.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for easyborg-0.12.0.tar.gz
Algorithm Hash digest
SHA256 ce688663928057cda7e10b8d4f1088410d26a3037b39a0f9b1b45b38e2709599
MD5 f06fe3bb950d8e2cdb73ac28fc5e1f08
BLAKE2b-256 a1ffcf406c9072e8c35849ccba6fb613e3e3c9f584049071de6f3f2fbfb8685b

See more details on using hashes here.

Provenance

The following attestation bundles were made for easyborg-0.12.0.tar.gz:

Publisher: pypi-publish.yml on sebastianhaberey/easyborg

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file easyborg-0.12.0-py3-none-any.whl.

File metadata

  • Download URL: easyborg-0.12.0-py3-none-any.whl
  • Upload date:
  • Size: 29.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for easyborg-0.12.0-py3-none-any.whl
Algorithm Hash digest
SHA256 33c0baf4743344b62fbc33cd00dadb7e4b9e2acba99c0d02a66b15737ac5b446
MD5 2787542d60cb55febff9dc259b77f733
BLAKE2b-256 09cce15777f65b00b316f71a6669845279298f4d1a155368b8c937d03db0e396

See more details on using hashes here.

Provenance

The following attestation bundles were made for easyborg-0.12.0-py3-none-any.whl:

Publisher: pypi-publish.yml on sebastianhaberey/easyborg

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page