1
0
Fork 0
mirror of https://github.com/SinTan1729/random.git synced 2024-12-26 13:18:35 -06:00
random/impfilesbk

51 lines
3.3 KiB
Text
Raw Normal View History

2021-12-28 02:54:26 -06:00
#!/bin/sh
2021-12-02 13:32:27 -06:00
# This script backs up some important stuff
2022-06-15 01:46:58 -05:00
# Setup location for home and backup directory
HMDIR="/home/sintan"
BKDIR="/mnt/storage/sintan"
2021-12-02 13:32:27 -06:00
echo `date` "| Backing up Documents..." | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/Documents/" "$BKDIR/Documents/" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo $'\n'`date` "| Done!" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo "--------------------------------------------------" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2021-12-17 22:09:50 -06:00
echo `date` "| Backing up Academics..." | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/Academics/" "$BKDIR/Academics/" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo $'\n'`date` "| Done!" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-01-13 12:04:50 -06:00
echo "--------------------------------------------------" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-01-13 12:04:50 -06:00
echo `date` "| Backing up Pictures..." | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/Pictures/" "$BKDIR/Pictures/" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo $'\n'`date` "| Done!" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-01-13 12:04:50 -06:00
echo "--------------------------------------------------" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-01-13 12:04:50 -06:00
echo `date` "| Backing up PhotoPrism index..." | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/PhotoPrism/storage/index-backup.sql" "$BKDIR/Programs/photoprism-backup.sql" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo $'\n'`date` "| Done!" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-07-20 18:31:02 -05:00
echo "--------------------------------------------------" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-07-20 18:31:02 -05:00
echo `date` "| Backing up Zotero..." | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/Zotero/" "$BKDIR/Zotero/" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo $'\n'`date` "| Done!" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-01-13 12:04:50 -06:00
echo "--------------------------------------------------" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-07-20 03:32:32 -05:00
echo `date` "| Backing up some config files and stuff..." | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-07-30 03:10:05 -05:00
rsync -aAXH --delete --stats --quiet --no-links --exclude={'*cache*','*Cache*'} --delete-excluded "$HMDIR/.config/" "$BKDIR/config/[dot]config/" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/.profile" "$BKDIR/config/[dot]profile" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/.bashrc" "$BKDIR/config/[dot]bashrc" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/.Xresources" "$BKDIR/config/[dot]Xresources" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/.local/bin/personal/" "$BKDIR/config/[dot]local_bin_personal/" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
rsync -aAXH --delete --stats "$HMDIR/.ssh/" "$BKDIR/config/[dot]ssh/" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo $'\n'`date` "| Done!" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
2022-06-15 01:31:38 -05:00
echo $'\n'"--------------------------------------------------" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx" | tee -a "$HMDIR/TempStorage/impfilesbk.log"
echo "--------------------------------------------------" | tee -a "$HMDIR/TempStorage/impfilesbk.log"