Automated Backups
How to setup automated backups of the Everdo database.
Overview
To back up the database while the app is running you need to use the sqlite3
tool - the official client for working with SQlite databases.
Setting up automated SQLite backups
- Create a backup script and make it executable.
- Test the script - make sure a backup is created and stored where you expect.
- Schedule the script to run periodically, for example as a cron job or as a scheduled task on Windows.
Here is an example bash script. You need to replace /home/user
with you unix user directory.
#!/bin/bash
TIMESTAMP=$(date +%F_%T | tr ':' '-')
sqlite3 /home/user/.config/everdo/db ".backup '/home/user/.config/everdo/backups/db_backup_$TIMESTAMP.sqlite'"
Last modified March 31, 2021