rsync-time-machine
Time Machine-style backups using rsync
Introducing rsync-time-machine.py - a Python port of the rsync-time-backup script, offering Time Machine-style backups using rsync. It creates incremental backups of files and directories to the destination of your choice. The backups are structured in a way that makes it easy to recover any file at any point in time. ๐
It works on Linux, macOS, and Windows (via WSL or Cygwin). The main advantage over Time Machine is flexibility, as it can backup from/to any filesystem and works on any platform. You can also backup to a Truecrypt drive without any problem. ๐
rsync-time-machine.py is fully tested, has no external dependencies (only Python โฅ3.7 ๐), is fully compatible with rsync-time-backup, offers pretty terminal output, and is fully typed! ๐
Features
- ๐ Each backup is in its own folder named after the current timestamp.
- ๐ Backup to/from remote destinations over SSH.
- ๐ Files that haven't changed from one backup to the next are hard-linked to the previous backup, saving space.
- โ ๏ธ Safety check - the backup will only happen if the destination has explicitly been marked as a backup destination.
- ๐ Resume feature - if a backup has failed or was interrupted, the tool will resume from there on the next backup.
- ๐ซ Exclude file - support for pattern-based exclusion via the
--exclude-fromrsync parameter. - ๐งน Automatically purge old backups based on a configurable expiration strategy.
- ๐ "latest" symlink that points to the latest successful backup.
Featured on
- the Real Python podcast: Episode 158: Building Python CI With Docker & Applying for a Hacker Initiative Grant @ 00:26:28
- Y Combinator Hacker News: Python Port of 600 Line Bash Script: rsync-time-machine.py for Rsync Backups (self-posted)
- Reddit /rpython: Ported a popular (untested) 600+ Line Bash Script ๐ to Python ๐: Introducing rsync-time-machine.py for Time Machine-Style Backups Using Rsync ๐โฐ (self-posted)
Support and Contributions
We appreciate your feedback and contributions! If you encounter any issues or have suggestions for improvements, please file an issue on the GitHub repository. We also welcome pull requests for bug fixes or new features.