From 8c5bcfb18cffd8f10e024a13371f0fd4e3126ce3 Mon Sep 17 00:00:00 2001 From: "Kevin Veen-Birkenbach [aka. Frantz]" Date: Fri, 15 May 2020 18:37:41 +0200 Subject: [PATCH] Implemented check for local files --- configuration/packages/client/pacman/general.txt | 1 + scripts/base.sh | 2 +- scripts/client/check.sh | 8 ++++++++ 3 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 scripts/client/check.sh diff --git a/configuration/packages/client/pacman/general.txt b/configuration/packages/client/pacman/general.txt index 9aae08b..c4ab203 100644 --- a/configuration/packages/client/pacman/general.txt +++ b/configuration/packages/client/pacman/general.txt @@ -15,6 +15,7 @@ yay make gcc cmake +fdupes # network analyze tools traceroute diff --git a/scripts/base.sh b/scripts/base.sh index e03332d..aa6986f 100644 --- a/scripts/base.sh +++ b/scripts/base.sh @@ -12,7 +12,7 @@ SCRIPT_PATH="$REPOSITORY_PATH/scripts/"; DATA_PATH="$DECRYPTED_PATH/data"; BACKUP_PATH="$DECRYPTED_PATH/backup"; TEMPLATE_PATH="$REPOSITORY_PATH/templates"; -LOCAL_REPOSITORIES_PATH="$HOME/Documents/repositories"; +LOCAL_REPOSITORIES_PATH="$HOME/Repositories"; declare -a BACKUP_LIST=("$HOME/.ssh/" \ "$HOME/.gitconfig" \ diff --git a/scripts/client/check.sh b/scripts/client/check.sh new file mode 100644 index 0000000..552a399 --- /dev/null +++ b/scripts/client/check.sh @@ -0,0 +1,8 @@ +#!/bin/bash +# @author Kevin Veen-Birkenbach +# shellcheck source=/dev/null # Deactivate SC1090 +source "$(dirname "$(readlink -f "${0}")")/../base.sh" || (echo "Loading base.sh failed." && exit 1) +echo "System check" +echo +info "Checking relevant home folders for duplicated files..." +fdupes -r "$HOME/Documents/" "$HOME/Downloads/" "$HOME/Images/" "$HOME/Desktop/" "$HOME/Music/" "$HOME/Pictures/" "$HOME/Videos"