- Put config_backup.sh to $HOME/config_backup.sh
- Configure the script:
- Fill in url to your github repo
- Provide paths and glob patterns for backup
- If needed: rename temporary backup directory
- Make the script executable:
chmod +x $HOME/config_backup.sh
- Run script:
./config_backup.sh
- Create temp directory
- Copy "backuped" files
- Init repository, push if there are any changes.
- Remove temp directory
- Create cron task to backup daily
- Do not back up full "$HOME/.config" directory. Some applications use it for cache :clown:
- Star this repo, write issues, make contributions
- Configure script with your test repository
-
docker build -t backup_test --build-arg="GITHUB_USERNAME=YOUR_GITHUB_USERNAME" --build-arg="YOUR_GITHUB_EMAIL=GITHUB_EMAIL" . docker run -it -v ~/.ssh:/root/.ssh -e SSH_AUTH_SOCK="$SSH_AUTH_SOCK" backup_test