2019-10-01 08:50:17 +02:00
|
|
|
#!/bin/bash
|
2019-10-01 11:59:31 +02:00
|
|
|
#
|
2019-10-01 08:50:17 +02:00
|
|
|
# This script contains the global program variables and functions
|
|
|
|
# @author Kevin Veen-Birkenbach [aka. Frantz]
|
2019-10-01 12:30:27 +02:00
|
|
|
#
|
|
|
|
# shellcheck disable=SC2034 #Deactivate checking of unused variables
|
|
|
|
REPOSITORY_PATH=$(readlink -f "$(dirname "$(readlink -f "${0}")")/../")
|
|
|
|
ENCRYPTED_PATH="$REPOSITORY_PATH/.encrypted";
|
|
|
|
DECRYPTED_PATH="$REPOSITORY_PATH/decrypted";
|
|
|
|
SCRIPT_PATH="$REPOSITORY_PATH/scripts";
|
|
|
|
DATA_PATH="$DECRYPTED_PATH/data";
|
|
|
|
BACKUP_PATH="$DECRYPTED_PATH/backup";
|
2019-12-03 13:37:39 +01:00
|
|
|
TEMPLATE_PATH="$REPOSITORY_PATH/templates";
|
|
|
|
LOCAL_REPOSITORIES_PATH="$HOME/Documents/repositories";
|
2020-05-02 12:12:51 +02:00
|
|
|
|
2019-12-03 14:22:10 +01:00
|
|
|
declare -a BACKUP_LIST=("$HOME/.ssh/" \
|
|
|
|
"$HOME/.gitconfig" \
|
|
|
|
"$HOME/.atom/config.cson" \
|
2019-12-16 21:56:59 +01:00
|
|
|
"$HOME/.local/share/rhythmbox/rhythmdb.xml" \
|
|
|
|
"$HOME/.config/keepassxc/keepassxc.ini" \
|
2019-12-03 14:22:10 +01:00
|
|
|
"$HOME/Documents/certificates/" \
|
|
|
|
"$HOME/Documents/recovery_codes/" \
|
|
|
|
"$HOME/Documents/identity/" \
|
|
|
|
"$HOME/Documents/passwords/" \
|
2019-12-16 21:56:59 +01:00
|
|
|
"$HOME/Documents/licenses/");
|
2020-05-02 12:17:36 +02:00
|
|
|
|
|
|
|
COLOR_RED=$(tput setaf 1)
|
|
|
|
COLOR_GREEN=$(tput setaf 2)
|
|
|
|
COLOR_YELLOW=$(tput setaf 3)
|
|
|
|
COLOR_BLUE=$(tput setaf 4)
|
|
|
|
COLOR_MAGENTA=$(tput setaf 5)
|
|
|
|
COLOR_CYAN=$(tput setaf 6)
|
|
|
|
COLOR_WHITE=$(tput setaf 7)
|
|
|
|
COLOR_RESET=$(tput sgr0)
|
|
|
|
|
|
|
|
HEADER(){
|
|
|
|
echo
|
|
|
|
echo "${COLOR_YELLOW}The"
|
|
|
|
base64 -d <<<"ICBfX19fXyAgICAgICAgICAgICAgICBfX19fXyAgICAgICAgICAgXyAgICAgICAgICAgICAgICAgCiAvIF9fX198ICAgICAgICAgICAgICAvIF9fX198ICAgICAgICAgfCB8ICAgICAgICAgICAgICAgIAp8IHwgICAgIF9fXyAgXyBfXyBfX198IChfX18gIF8gICBfIF9fX3wgfF8gX19fIF8gX18gX19fICAKfCB8ICAgIC8gXyBcfCAnX18vIF8gXFxfX18gXHwgfCB8IC8gX198IF9fLyBfIFwgJ18gYCBfIFwgCnwgfF9fX3wgKF8pIHwgfCB8ICBfXy9fX19fKSB8IHxffCBcX18gXCB8fCAgX18vIHwgfCB8IHwgfAogXF9fX19fXF9fXy98X3wgIFxfX198X19fX18vIFxfXywgfF9fXy9cX19cX19ffF98IHxffCB8X3wKICAgICAgICAgICAgICAgICAgICAgICAgICAgICAgX18vIHwgICAgICAgICAgICAgICAgICAgICAgCiAgICAgICAgICAgICAgICAgICAgICAgICAgICAgfF9fXy8gICAgICAgICAgICAgICAgICAgICAgIAo="
|
|
|
|
echo "is administration tool designed from and for Kevin Veen-Birkenbach."
|
|
|
|
echo
|
|
|
|
echo "Licensed under GNU GENERAL PUBLIC LICENSE Version 3"
|
|
|
|
echo "${COLOR_RESET}"
|
|
|
|
}
|
|
|
|
|
|
|
|
HEADER
|