diff --git a/install.sh b/install.sh index 442a8c3..0fe8372 100755 --- a/install.sh +++ b/install.sh @@ -16,11 +16,22 @@ function link() { fi } +# update/clone repositories +[[ ! -d "repositories/punktdateien-bashrc" ]] && git clone "https://git.staropensource.de/JeremyStarTM/punktdateien-bashrc.git" repositories/punktdateien-bashrc +( + cd repositories/punktdateien-bashrc || ( + echo ":: Error: Can't cd into repositories/punktdateien-bashrc" + exit 1 + ) + git pull +) + # create directories #mkdir -p "/unused/" # bash configuration link "lone-files/bashrc" "etc/bash.bashrc" +link "repositories/punktdateien-bashrc" "/etc/bashrc.d" # locales & stuff link "lone-files/locale.gen" "etc/locale.gen" diff --git a/lone-files/bashrc b/lone-files/bashrc index 9ca1fe1..2f8129c 100755 --- a/lone-files/bashrc +++ b/lone-files/bashrc @@ -23,6 +23,8 @@ if [[ -r /usr/share/bash-completion/bash_completion ]]; then . /usr/share/bash-completion/bash_completion fi +export "BASHRCD_SYSTEM=true" +source "/etc/bashrc.d/startup.sh" if [ "${UID}" == "0" ]; then env "BASHRC=true" sysdotfiles-updatechecker fi diff --git a/uninstall.sh b/uninstall.sh index a9e8597..3fbec4a 100755 --- a/uninstall.sh +++ b/uninstall.sh @@ -10,13 +10,14 @@ function unlink() { } # repositories -[[ -n "$REMOVE_REPOSITORIES" ]] && true +[[ -n "$REMOVE_REPOSITORIES" ]] && rm -rf repositories # install bit [[ -n "$REMOVE_INSTALLBIT" ]] && rm -rf "/etc/.jstm_dotfiles" # bash configuration unlink "etc/bash.bashrc" +unlink "etc/bashrc.d" # locales & stuff unlink "etc/locale.gen"