diff options
author | Guangxiong Lin <[email protected]> | 2023-03-01 07:54:15 +0800 |
---|---|---|
committer | Guangxiong Lin <[email protected]> | 2023-03-01 07:55:43 +0800 |
commit | d638d8d3a0b6af5d0e7bc5b75ff48a0634214b0c (patch) | |
tree | d90df55f37d787e43610a2a3bfec1195a0b636fb | |
parent | 5dba1d295ab526fbb39f47676a47c1a45aecde49 (diff) | |
download | dotfiles-d638d8d3a0b6af5d0e7bc5b75ff48a0634214b0c.tar.gz dotfiles-d638d8d3a0b6af5d0e7bc5b75ff48a0634214b0c.tar.bz2 dotfiles-d638d8d3a0b6af5d0e7bc5b75ff48a0634214b0c.zip |
Remove backup script
-rwxr-xr-x | scripts/backup.sh | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/scripts/backup.sh b/scripts/backup.sh deleted file mode 100755 index ebb7e21..0000000 --- a/scripts/backup.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env bash - -# Delete old snapshots -find "/snapshots/$USER" -maxdepth 1 -mtime +120 -type d -execdir rm -rf {} + - -exclude_file="$HOME/backup.exclude" - -OPT="-aPh" -EXCLUDE="--exclude-from=$exclude_file" -LATEST="/snapshots/$USER/latest" -LINK="--link-dest=$LATEST" -SRC="/home/$USER/" -SNAP="/snapshots/$USER/" -date=$(date "+%Y-%b-%d:_%T") - -[ ! -d $SNAP ] && mkdir -p $SNAP - - -rsync $OPT $LINK $EXCLUDE $SRC ${SNAP}$date - -rm -f $LATEST -ln -s ${SNAP}$date $LATEST |