Skip to content

Instantly share code, notes, and snippets.

View cbruegg's full-sized avatar

Christian Brüggemann cbruegg

View GitHub Profile
@cbruegg
cbruegg / dropbox-differential-backup.sh
Last active November 12, 2024 19:18
Script to keep differential backups of your Dropbox with a maximum storage quota using rclone. Uses hardlinks to save space.
#!/bin/bash
# Configuration
RCLONE_REMOTE="dropbox:/" # Adjust this if you don't want the full Dropbox
BACKUP_DIR="/path/to/backups" # Adjust to your local backup directory
SNAPSHOT_LIMIT=500000 # Max usage in MB (500 GB)
# Create backup directory if it doesn't exist
mkdir -p "$BACKUP_DIR"