mirror of
https://github.com/SinTan1729/random.git
synced 2024-12-25 20:58:37 -06:00
35 lines
1.8 KiB
Bash
35 lines
1.8 KiB
Bash
#!/bin/sh
|
|
|
|
# This script backs up some important stuff
|
|
|
|
# Setup location for home
|
|
HMDIR=/home/sintan
|
|
BKDIR=/mnt/storage/sintan
|
|
|
|
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
|
|
|
|
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
|
|
|
|
echo "----------" | tee -a $HMDIR/TempStorage/impfilesbk.log
|
|
|
|
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
|
|
|
|
echo "----------" | tee -a $HMDIR/TempStorage/impfilesbk.log
|
|
|
|
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
|
|
|
|
echo `date` "| Backing up some config files and stuff..." | tee -a $HMDIR/TempStorage/impfilesbk.log
|
|
rsync -aAXH --delete --stats $HMDIR/.config $HMDIR/.tmux.conf $HMDIR/.profile $HMDIR/.bashrc $HMDIR/.Xresources $HMDIR/.local/bin/personal $HMDIR/.ssh $BKDIR/config/ | tee -a $HMDIR/TempStorage/impfilesbk.log
|
|
echo $'\n'`date` "| Done!" | tee -a $HMDIR/TempStorage/impfilesbk.log
|
|
|
|
echo $'\n'"--------------------------------------------------" | tee -a $HMDIR/TempStorage/impfilesbk.log
|