autobackup
Usage
Installation
Install latest from the GitHub repository:
$ pip install git+https://github.com/johnowhitaker/autobackup.git
or from pypi
$ pip install autobackup
How to use
autobackup src dest will make a copy of src (which can be a file or
a directory) inside dir in a folder with the current date+time, and
clean up any old backups based on the following rules:
- The most recent 5 backups are kept
- For each number of days in
--max_ages(default is “2,14,60”) the oldest one below that age is kept.
This ensures that you have a few recent backups, one up to 2 days old, one up to 2 weeks old and one up to 2 months old.
To run this script hourly,
- Create a service file (e.g.
/etc/systemd/system/backup.service):
[Unit]
Description=Hourly Backup Service
[Service]
ExecStart=autobackup /path/to/src /path/to/dest
[Install]
WantedBy=multi-user.target
- Create a timer file (e.g.
/etc/systemd/system/backup.timer):
[Unit]
Description=Run Backup Service Hourly
[Timer]
OnCalendar=hourly
[Install]
WantedBy=timers.target
- Enable and start the timer:
sudo systemctl enable backup.timer
sudo systemctl start backup.timer
Metadata
Release files for autobackup 0.0.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| autobackup-0.0.4.tar.gz | 9.3 kB | Without provenance | Details for autobackup-0.0.4.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| autobackup-0.0.4-py3-none-any.whl | Python 3 | none | any | Details for autobackup-0.0.4-py3-none-any.whl |
Total release size: 17.8 kB
Release files / autobackup-0.0.4.tar.gz
| Download URL | autobackup-0.0.4.tar.gz |
|---|---|
| Size | 9.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
256b56319c5a424904548e4850a785e8d0930d534cc4fd9a614652ceef2a4fa7
|
|
BLAKE2b-256 checksum How to use checksums |
836ea7036afc03b7864194ab3bae7949fd0c6981de98305cee967ffe280f5137
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.9
|
Release files / autobackup-0.0.4-py3-none-any.whl
| Download URL | autobackup-0.0.4-py3-none-any.whl |
|---|---|
| Size | 8.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fcd6a940eca23b4a7f12ae37451a94027a5c0ac9ef6a1748f5ad1e5b9554f810
|
|
BLAKE2b-256 checksum How to use checksums |
a85b241f903e42d353f44e86f28697d9502687da793a3d592f9f2a80b20ea7f5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.1 CPython/3.11.9
|
Security for autobackup 0.0.4
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.